-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (38 loc) · 1.11 KB
/
test.yml
File metadata and controls
46 lines (38 loc) · 1.11 KB
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
name: Tests
on:
push:
branches: [main]
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: go.mod
- name: Install deps
run: sudo apt update && sudo apt install -y libgpgme-dev
- name: Install go-junit-report
run: |
export GOPATH="$HOME/go/"
export PATH=$PATH:$GOPATH/bin
go install github.com/jstemmer/go-junit-report@latest
- name: Generate
run: go generate ./...
- name: Run tests
run: |
export GOPATH="$HOME/go/"
export PATH=$PATH:$GOPATH/bin
go test -v ./... | go-junit-report -set-exit-code > report.xml
env:
R2_ACCOUNT_ID: ${{ secrets.R2_ACCOUNT_ID }}
R2_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }}
R2_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }}
- name: Summarize Test Results
if: always()
uses: test-summary/action@v2
with:
paths: report.xml
show: all