-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
50 lines (42 loc) · 1.58 KB
/
cov.yaml
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: NATS Server Code Coverage
on:
workflow_dispatch: {}
schedule:
- cron: "40 4 * * *"
jobs:
nightly_coverage:
runs-on: ubuntu-latest
env:
GOPATH: /home/runner/work/nats-server
GO111MODULE: "on"
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
path: src/github.com/nats-io/nats-server
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: src/github.com/nats-io/nats-server/go.mod
cache-dependency-path: src/github.com/nats-io/nats-server/go.sum
- name: Run code coverage
shell: bash --noprofile --norc -x -eo pipefail {0}
run: |
set -e
cd src/github.com/nats-io/nats-server
./scripts/cov.sh upload
set +e
- name: Convert coverage.out to coverage.lcov
# Use commit hash here to avoid a re-tagging attack, as this is a third-party action
# Commit 4e1989767862652e6ca8d3e2e61aabe6d43be28b = tag v1.1.1
uses: jandelgado/gcov2lcov-action@4e1989767862652e6ca8d3e2e61aabe6d43be28b
with:
infile: acc.out
working-directory: src/github.com/nats-io/nats-server
- name: Coveralls
# Use commit hash here to avoid a re-tagging attack, as this is a third-party action
# Commit 43f11c4e058174f808ee9cd63701b6c42fe3f5e3 = tag v2.3.2
uses: coverallsapp/github-action@cfd0633edbd2411b532b808ba7a8b5e04f76d2c8
with:
github-token: ${{ secrets.github_token }}
file: src/github.com/nats-io/nats-server/coverage.lcov