forked from klaviyo/reviews-imgproxy
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (35 loc) · 1003 Bytes
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Test
on:
- push
- pull_request
env:
CGO_LDFLAGS_ALLOW: "-s|-w"
jobs:
test:
runs-on: ubuntu-latest
container:
image: darthsim/imgproxy-ci:202310031902
strategy:
matrix:
go-version: ["1.21.x", "1.20.x", "1.19.x"]
vips-version: ["8.14", "8.13"]
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- name: Cache mods
uses: actions/cache@v3
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ matrix.go-version }}-${{ hashFiles('**/go.sum') }}
- name: Download mods
run: go mod download
- name: Test
run: go test ./...
env:
LD_LIBRARY_PATH: "/usr/local/lib:/root/vips/${{ matrix.vips-version }}/lib"
PKG_CONFIG_PATH: "/usr/local/lib/pkgconfig:/root/vips/${{ matrix.vips-version }}/lib/pkgconfig"