-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (40 loc) · 938 Bytes
/
ci.yml
File metadata and controls
50 lines (40 loc) · 938 Bytes
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
name: ci
on:
workflow_dispatch:
push:
branches:
- '**'
pull_request:
branches:
- main
- develop
permissions:
contents: read
packages: write
actions: write
jobs:
build-and-test:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: checkout
uses: actions/checkout@v3
- name: setup go
uses: actions/setup-go@v4
with:
go-version: 1.23.5
- name: setup test infrastructure
run: docker compose -f test/compose.yml up -d
- name: install dependencies
run: go mod tidy
- name: build
run: go build ./...
- name: test
run: go test ./... -v -coverprofile=coverage.out
- name: cleanup history
uses: ./.github/actions/cleanup-history
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
days_old: 1
page_count: 20