mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
ci: collect code coverage (#5516)
https://app.codecov.io/gh/Chatterino/chatterino2
This commit is contained in:
parent
44abb1901f
commit
21186df058
2 changed files with 24 additions and 3 deletions
7
.codecov.yml
Normal file
7
.codecov.yml
Normal file
|
@ -0,0 +1,7 @@
|
|||
comment: false
|
||||
ignore:
|
||||
- "/usr/local*/**/*"
|
||||
- "/usr/include/**/*"
|
||||
- "lib/"
|
||||
- "**/ui_*.h"
|
||||
- "**/moc_*.cpp"
|
20
.github/workflows/test.yml
vendored
20
.github/workflows/test.yml
vendored
|
@ -5,6 +5,10 @@ on:
|
|||
pull_request:
|
||||
workflow_dispatch:
|
||||
merge_group:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- main
|
||||
|
||||
env:
|
||||
TWITCH_PUBSUB_SERVER_TAG: v1.0.7
|
||||
|
@ -39,11 +43,11 @@ jobs:
|
|||
- name: Create build directory (Ubuntu)
|
||||
run: mkdir build-test
|
||||
|
||||
- name: Install googlebench
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt update
|
||||
sudo apt -y install \
|
||||
libbenchmark-dev
|
||||
sudo DEBIAN_FRONTEND=noninteractive apt -y --no-install-recommends install \
|
||||
libbenchmark-dev gcovr gnupg
|
||||
|
||||
- name: Build (Ubuntu)
|
||||
run: |
|
||||
|
@ -55,6 +59,8 @@ jobs:
|
|||
-DCMAKE_PREFIX_PATH="$Qt6_DIR/lib/cmake" \
|
||||
-DBUILD_WITH_QT6="$C2_BUILD_WITH_QT6" \
|
||||
-DCHATTERINO_STATIC_QT_BUILD=On \
|
||||
-DCHATTERINO_GENERATE_COVERAGE=On \
|
||||
-DCMAKE_BUILD_TYPE=Debug \
|
||||
..
|
||||
cmake --build .
|
||||
working-directory: build-test
|
||||
|
@ -84,3 +90,11 @@ jobs:
|
|||
cd ../build-test
|
||||
ctest --repeat until-pass:4 --output-on-failure --exclude-regex ClassicEmoteNameFiltering
|
||||
working-directory: build-test
|
||||
|
||||
- name: Upload coverage reports to Codecov
|
||||
uses: codecov/codecov-action@v4.5.0
|
||||
with:
|
||||
token: ${{ secrets.CODECOV_TOKEN }}
|
||||
plugin: gcov
|
||||
fail_ci_if_error: true
|
||||
verbose: true
|
||||
|
|
Loading…
Reference in a new issue