-
Notifications
You must be signed in to change notification settings - Fork 239
43 lines (41 loc) · 1.31 KB
/
Copy pathcoverage.yml
File metadata and controls
43 lines (41 loc) · 1.31 KB
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
name: Coverage
on:
workflow_dispatch:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
linux-coverage:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
with:
fetch-depth: 0
- name: Install dependencies
run: |
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install -y g++-16
wget --quiet https://github.com/linux-test-project/lcov/releases/download/v2.4/lcov-2.4.tar.gz
tar -xf lcov-2.4.tar.gz
cd lcov-2.4
sudo make install
sudo cpan App::cpanminus
sudo cpanm --notest Capture::Tiny DateTime
- name: Configure
run: cmake --preset=ci-coverage
- name: Build
run: cmake --build build/ci-coverage -j8
- name: Run tests
run: ctest --test-dir build/ci-coverage --output-on-failure --no-tests=error -j8
- name: Process coverage info
run: cmake --build build/ci-coverage -t coverage
- name: Submit to codecov.io
uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v6
with:
files: build/ci-coverage/coverage.info
plugins: noop
disable_search: true
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true