Skip to content

Commit e3d1875

Browse files
authored
Merge pull request #13 from arduino/per1234/test-workflow-no-artifact
Add CI workflow to run tests
2 parents d2fe340 + 9fe8361 commit e3d1875

File tree

1 file changed

+51
-0
lines changed

1 file changed

+51
-0
lines changed

Diff for: .github/workflows/test.yml

+51
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Run tests
2+
3+
on:
4+
push:
5+
paths:
6+
- ".github/workflows/test.yml"
7+
- "Taskfile.yml"
8+
- "go.mod"
9+
- "go.sum"
10+
- "**/*.go"
11+
- "**/testdata/**"
12+
pull_request:
13+
paths:
14+
- ".github/workflows/test.yml"
15+
- "Taskfile.yml"
16+
- "go.mod"
17+
- "go.sum"
18+
- "**/*.go"
19+
- "**/testdata/**"
20+
21+
jobs:
22+
test-go:
23+
strategy:
24+
matrix:
25+
operating-system:
26+
- ubuntu-latest
27+
- windows-latest
28+
- macOS-latest
29+
30+
runs-on: ${{ matrix.operating-system }}
31+
32+
steps:
33+
- name: Checkout local repository
34+
uses: actions/checkout@v2
35+
36+
- name: Install Go
37+
uses: actions/setup-go@v2
38+
with:
39+
go-version: "1.14"
40+
41+
- name: Install Taskfile
42+
uses: arduino/actions/setup-taskfile@master
43+
with:
44+
repo-token: ${{ secrets.GITHUB_TOKEN }}
45+
version: 3.x
46+
47+
- name: Build
48+
run: task build
49+
50+
- name: Run unit tests
51+
run: task go:test-unit

0 commit comments

Comments
 (0)