-
-
Notifications
You must be signed in to change notification settings - Fork 23
49 lines (42 loc) · 1.1 KB
/
testing.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
---
name: "Test"
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref }}
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
on:
push:
branches: [ master ]
pull_request:
jobs:
test:
name: Test
runs-on: ubuntu-latest
strategy:
matrix:
go-version: [ '1.19', '1.20', '1.21', 'stable' ]
timeout-minutes: 10
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Setup dependencies
uses: ./.github/actions/setup-deps
with:
go-version: ${{ matrix.go-version }}
token: ${{ secrets.GITHUB_TOKEN }}
- name: Run tests
run: task test
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
if: success()
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.txt
fail_ci_if_error: false
summary:
name: Test
runs-on: ubuntu-latest
needs: [ test ]
timeout-minutes: 1
steps:
- name: Dummy task
run: echo 'Dummy summary task to have one PR status for all tested versions'