Skip to content

Commit 0359a3e

Browse files
author
Romain Dartigues
committed
CI: introduce unit-test GH Action
1 parent fdffe23 commit 0359a3e

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

.github/workflows/unit-tests.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: unit-tests
2+
3+
on:
4+
pull_request: ~
5+
push: ~
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: checkout
12+
uses: actions/checkout@v4
13+
with:
14+
fetch-depth: 0
15+
16+
- name: set up go
17+
uses: actions/setup-go@v5
18+
with:
19+
go-version: "1.22"
20+
21+
- name: cache go modules
22+
uses: actions/cache@v4
23+
with:
24+
path: ~/go/pkg/mod
25+
key: "${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}"
26+
restore-keys: |
27+
${{ runner.os }}-go-
28+
29+
- name: tests
30+
run: |
31+
go test -v ./...

0 commit comments

Comments
 (0)