Skip to content

Commit f29e5bc

Browse files
committed
chore: added CI
1 parent 62bef8a commit f29e5bc

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

.github/workflows/ci.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: ci
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
- backend
8+
9+
jobs:
10+
tests:
11+
name: Tests
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Check out code
16+
uses: actions/checkout@v4
17+
18+
- name: Set up Go
19+
uses: actions/setup-go@v5
20+
with:
21+
go-version: '1.24.4'
22+
23+
- name: Run unit tests
24+
run: go test ./... -cover
25+
26+
style:
27+
name: Style
28+
runs-on: ubuntu-latest
29+
30+
steps:
31+
- name: Check out code
32+
uses: actions/checkout@v4
33+
34+
- name: Set up Go
35+
uses: actions/setup-go@v5
36+
with:
37+
go-version: '1.24.4'
38+
39+
- name: Check formatting
40+
run: test -z $(go fmt ./...)
41+
42+
- name: Install staticcheck
43+
run: go install honnef.co/go/tools/cmd/staticcheck@latest
44+
45+
- name: Run staticcheck
46+
run: staticcheck ./...

0 commit comments

Comments
 (0)