-
Notifications
You must be signed in to change notification settings - Fork 79
50 lines (48 loc) · 1.35 KB
/
go.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
39
40
41
42
43
44
45
46
47
48
49
50
name: Go Test
on:
push:
pull_request:
branches: [master]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
go: [stable, oldstable]
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go }}
- run: go install github.com/ory/go-acc@latest
- run: go-acc -o coverage.txt ./... -- -race -tags integration
- run: make test-trust
- uses: codecov/codecov-action@v3
test-hsm:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: stable
- run: sudo apt-get update && sudo apt-get install -y softhsm2
- run: sudo cp -r tests/testdata/tokens/* /var/lib/softhsm/tokens
- run: go install github.com/ory/go-acc@latest
- run: go-acc -o coverage.txt ./... -- -race -tags pkcs11
env:
TEST_SOFT_HSM: true
- uses: codecov/codecov-action@v3
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go }}
- name: Install golint
run: go install ./vendor/golang.org/x/lint/golint
- name: Go Lint
run: make gokeyless vet lint