aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Rusakov <Kitsune-Ral@users.sf.net>2021-12-22 17:31:37 +0100
committerAlexey Rusakov <Kitsune-Ral@users.sf.net>2021-12-24 02:34:27 +0100
commita08348007dd0a73a40b7b1d755b3affc963b5b80 (patch)
treeaf81dff7e7873d9777a659ceceec2a4940c8f3fc
parent42eaf3671c656088f8d038f83973f0931ad7051c (diff)
downloadlibquotient-a08348007dd0a73a40b7b1d755b3affc963b5b80.tar.gz
libquotient-a08348007dd0a73a40b7b1d755b3affc963b5b80.zip
Sonar: add coverage analysis
-rw-r--r--.github/workflows/sonar.yml8
1 files changed, 6 insertions, 2 deletions
diff --git a/.github/workflows/sonar.yml b/.github/workflows/sonar.yml
index ae96aebc..c8ddca66 100644
--- a/.github/workflows/sonar.yml
+++ b/.github/workflows/sonar.yml
@@ -53,7 +53,8 @@ jobs:
echo "CXX=g++-10" >>$GITHUB_ENV
mkdir -p $HOME/.sonar
echo "CMAKE_ARGS=-G Ninja -DCMAKE_BUILD_TYPE=RelWithDebInfo -DBUILD_SHARED_LIBS=false \
- -DCMAKE_INSTALL_PREFIX=~/.local -DCMAKE_PREFIX_PATH=~/.local" >>$GITHUB_ENV
+ -DCMAKE_INSTALL_PREFIX=~/.local -DCMAKE_PREFIX_PATH=~/.local" \
+ -DCMAKE_CXX_FLAGS=--coverage >>$GITHUB_ENV
cmake -E make_directory ${{ runner.workspace }}/build
- name: Build and install olm
@@ -110,4 +111,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: |
- $HOME/.sonar/sonar-scanner*/bin/sonar-scanner --define sonar.host.url="${{ env.SONAR_SERVER_URL }}" --define sonar.cfamily.build-wrapper-output="${{ env.BUILD_WRAPPER_OUT_DIR }}"
+ $HOME/.sonar/sonar-scanner*/bin/sonar-scanner \
+ -Dsonar.host.url="${{ env.SONAR_SERVER_URL }}" \
+ -Dsonar.cfamily.build-wrapper-output="${{ env.BUILD_WRAPPER_OUT_DIR }}" \
+ -Dsonar.cfamily.gcov.reportsPath=build/coverage