-
Notifications
You must be signed in to change notification settings - Fork 109
120 lines (119 loc) · 3.33 KB
/
coverage.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
# DO NOT EDIT - GENERATED FROM .github/workflows/coverage.ys
name: coverage
defaults:
run:
shell: bash -e -x {0}
'on':
workflow_dispatch: null
push:
branches:
- master
pull_request:
branches:
- master
env:
PROJ_PFX_TARGET: ryml-
PROJ_PFX_CMAKE: RYML_
CMAKE_FLAGS: -DRYML_TEST_SUITE=ON
NUM_JOBS_BUILD: null
jobs:
coverage:
if: always()
continue-on-error: false
name: cov/c++${{matrix.std}}/${{matrix.namesfx}}
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
include:
- std: 11
namesfx: 64bit
cmk: -DCMAKE_CXX_FLAGS=-m64
- std: 11
namesfx: 64bit_dbg
cmk: -DCMAKE_CXX_FLAGS=-m64 -DRYML_DBG=ON
- std: 17
namesfx: 64bit
cmk: -DCMAKE_CXX_FLAGS=-m64
- std: 17
namesfx: 64bit_dbg
cmk: -DCMAKE_CXX_FLAGS=-m64 -DRYML_DBG=ON
- std: 11
namesfx: 32bit
cmk: -DCMAKE_CXX_FLAGS=-m32
- std: 11
namesfx: 32bit_dbg
cmk: -DCMAKE_CXX_FLAGS=-m32 -DRYML_DBG=ON
- std: 17
namesfx: 32bit
cmk: -DCMAKE_CXX_FLAGS=-m32
- std: 17
namesfx: 32bit_dbg
cmk: -DCMAKE_CXX_FLAGS=-m32 -DRYML_DBG=ON
env:
GCC_VERSION: 13
LCOV_ARGS: -v --ignore-errors mismatch,mismatch --ignore-errors unused,unused
BUILD_ID: cpp${{matrix.std}}_${{matrix.namesfx}}
CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}}
steps:
- name: checkout (action)
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: install compiler
run: |
sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install -y \
build-essential \
cmake \
git \
lcov \
linux-libc-dev:i386 \
libc6:i386 \
libc6-dev:i386 \
libc6-dbg:i386 \
g++-$GCC_VERSION \
g++-$GCC_VERSION-multilib
- name: show info
run: source .github/setenv.sh && c4_show_info
- name: configure
run: |
cmake -B build/$BUILD_ID \
-DCMAKE_BUILD_TYPE=Coverage \
-DRYML_BUILD_TESTS=ON \
-DRYML_COVERAGE_LCOV_ARGS=" $LCOV_ARGS " \
-DRYML_COVERAGE_CODECOV=ON \
${{matrix.cmk}}
- name: build
run: |
cmake --build build/$BUILD_ID --verbose --target ryml-test-build --parallel
- name: run
run: |
cmake --build build/$BUILD_ID --verbose --target ryml-coverage
- name: upload artifacts
uses: actions/upload-artifact@v4
with:
name: coverage-${{env.BUILD_ID}}
path: |
build/$BUILD_ID/lcov
build/$BUILD_ID/coverage3-final_filtered.lcov
- name: upload codecov
run: |
cmake --build build/$BUILD_ID --target ryml-coverage-submit-codecov --verbose
- name: upload coveralls
uses: coverallsapp/github-action@v2
with:
github-token: ${{secrets.COVERALLS_REPO_TOKEN}}
parallel: true
files: build/${{env.BUILD_ID}}/coverage3-final_filtered.lcov
coveralls_finish:
needs: coverage
if: ${{always()}}
runs-on: ubuntu-24.04
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@v2
with:
parallel-finished: true