-
Notifications
You must be signed in to change notification settings - Fork 23
43 lines (35 loc) · 900 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
39
40
41
42
43
name: ci
on:
push:
tags:
- v*
branches:
- main
- release-*
pull_request:
jobs:
test:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
go-version: [1.20.x, 1.21.x]
race: ["-race", ""]
steps:
- name: checkout
uses: actions/checkout@v2
- name: install go ${{ matrix.go-version }}
uses: actions/setup-go@v2
with:
stable: '!contains(${{ matrix.go-version }}, "beta") && !contains(${{ matrix.go-version }}, "rc")'
go-version: ${{ matrix.go-version }}
- name: install bats
uses: mig4/setup-bats@v1
with:
bats-version: 1.4.1
- name: build
run: make build EXTRA_BUILD_FLAGS="${{ matrix.race }}"
- name: unit tests
run: make test-unit EXTRA_TEST_FLAGS="${{ matrix.race }}"
- name: integration tests
run: make test-integration