-
Notifications
You must be signed in to change notification settings - Fork 362
55 lines (44 loc) · 1.05 KB
/
unit-tests.yaml
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
51
52
53
54
55
name: Unit test
on:
release:
types: [created]
pull_request:
branches:
- main
- v6
paths:
- "**.go"
- "!e2e/**" # exclude files from e2e tests
- ".github/workflows/unit-tests.yaml"
env:
GO111MODULE: on
GOFLAGS: -mod=vendor
jobs:
test-unit:
strategy:
matrix:
os: [macos-latest, ubuntu-latest]
name: unit-test-${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: "1.22"
- name: Check out code into the Go module directory
uses: actions/checkout@v1
- name: Test
run: ./hack/coverage.bash
test-unit-windows:
runs-on: windows-latest
name: unit-test-windows-latest
steps:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: "1.22"
- name: Check out code into the Go module directory
uses: actions/checkout@v1
- name: Test
run: ./hack/coverage.bash
shell: bash