File tree Expand file tree Collapse file tree 1 file changed +48
-0
lines changed
Expand file tree Collapse file tree 1 file changed +48
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Go Test
2+
3+ on : [push, pull_request]
4+
5+ jobs :
6+ build :
7+ runs-on : ubuntu-latest
8+
9+ strategy :
10+ matrix :
11+ go-version :
12+ - 1.20.x
13+ - 1.21.x
14+ - 1.22.x
15+ - 1.23.x
16+
17+ steps :
18+ - name : Checkout
19+ uses : actions/checkout@v4
20+
21+ - name : Setup Go
22+ uses : actions/setup-go@v4
23+ with :
24+ go-version : ${{ matrix.go-version }}
25+
26+ - name : Cache modules
27+ uses : actions/cache@v4
28+ with :
29+ path : |
30+ ~/.cache/go-build
31+ ~/go/pkg/mod
32+ key : ${{ runner.os }}-go-${{ matrix.go-version }}-${{ hashFiles('**/go.sum') }}
33+ restore-keys : |
34+ ${{ runner.os }}-go-${{ matrix.go-version }}-
35+ ${{ runner.os }}-go-
36+ ${{ runner.os }}-
37+
38+ - name : Install dependencies
39+ run : go mod download
40+
41+ - name : Set CLOUDINARY_URL
42+ run : |
43+ export CLOUDINARY_URL=$(bash scripts/get_test_cloud.sh)
44+ echo "CLOUDINARY_URL=$CLOUDINARY_URL" >> $GITHUB_ENV
45+ echo "cloud_name: $(echo $CLOUDINARY_URL | cut -d'@' -f2)"
46+
47+ - name : Run tests
48+ run : go test -v ./...
You can’t perform that action at this time.
0 commit comments