-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (41 loc) · 1.2 KB
/
ci.yml
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:
# Pushes and pulls to all branches
push:
pull_request:
# Run on the first day of every month
schedule:
- cron: "0 0 1 * *"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
# Build and test everything
build:
runs-on: ubuntu-latest
steps:
# Checkout the code
- name: Checkout Code
uses: actions/checkout@v4
# Set up the GoLang environment
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.21
# Download all the tools used in the steps that follow
- name: Set up Tools
run: |
go install github.com/fzipp/gocyclo/cmd/[email protected]
go install github.com/mattn/[email protected]
# Run all the unit-tests
- name: Test
run: |
make test
# Run the benchmarks to manually ensure no performance degradation
- name: Benchmark
run: |
make bench
# Upload all the unit-test coverage reports to Coveralls
- name: Upload Coverage Report
env:
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: goveralls -service=github -coverprofile=.coverprofile