-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
126 additions
and
217 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: CI | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- master | ||
- develop | ||
- feature/** | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-24.04 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Install pre-reqs | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install black | ||
- name: Shellcheck | ||
run: | | ||
set -xe | ||
shellcheck scripts/lcov-jenkins-gcc-13.sh | ||
- name: Black | ||
run: | | ||
set -xe | ||
black scripts/gcov-compare.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
|
||
## GCOV/LCOV PROCESSING | ||
|
||
- lcov-jenkins.sh: a script used by Jenkins jobs to process test coverage, and output lcov/gcov results. | ||
- lcov-development.sh: almost identical to lcov-jenkins.sh. However the purpose of this script is to test locally in a container, and possibly use this as a location to add new features that will eventually be migrated into the live production in lcov-jenkins.sh. Submit proposed updates here. | ||
- lcov-jenkins-gcc-13.sh: a script used by Jenkins jobs to process test coverage, and output lcov/gcov results. | ||
- gcov-compare.py: Compares the coverage changes of a pull request, and displays a sort of "chart" indicating if coverage has increased or decreased. | ||
|
||
Modifying lcov-jenkins-gcc-13.sh affects all current jobs. Therefore, when testing, add scripts such as lcov-jenkins-gcc-16-experimental.sh, etc. | ||
|
||
See docs/README.md for instructions about running lcov in a local test environment. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
|
||
## LCOV and GCOVR scripts | ||
|
||
Generate coverage reports on pull requests. | ||
|
||
## Instructions to test gcovr locally | ||
|
||
Run tests in a docker container such as ubuntu:24.04, or the latest LTS Ubuntu. | ||
|
||
Configure a few variables and settings that would already be available in a Jenkins job but | ||
if run in standalone mode would need to be set. The following code might be manually | ||
copied into the script. Or run this in a shell first. | ||
|
||
``` | ||
apt-get update | ||
apt-get install sudo | ||
mkdir -p test | ||
cd test | ||
export REPONAME=url | ||
export ORGANIZATION=cppalliance | ||
ghprbTargetBranch=develop | ||
export JOBFOLDER="${REPONAME}_job_folder" | ||
echo "Initial cleanup. Remove job folder" | ||
rm -rf ${JOBFOLDER} | ||
echo "Remove target folder" | ||
rm -rf ${REPONAME} | ||
echo "Remove boost-root" | ||
rm -rf boost-root | ||
git clone https://github.com/$ORGANIZATION/$REPONAME ${JOBFOLDER} | ||
cd ${JOBFOLDER} | ||
# Then proceed with the lcov processing | ||
./lcov-jenkins-gcc-13.sh # or the name of the current script, which may be gcc-16, etc. | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
File renamed without changes.
Oops, something went wrong.