Skip to content

Commit

Permalink
chore: added coverage multiprocessing config for CI master builds
Browse files Browse the repository at this point in the history
  • Loading branch information
jstucke committed Dec 10, 2024
1 parent ad4d6d8 commit a9a9a8e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/build_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,11 @@ jobs:
shell: 'script -q -e -c "bash {0}"'
run: |
python3 -m pip install codecov
pytest --cov=.
if [ $(git rev-parse --abbrev-ref HEAD) == "master" ];
then # run coverage with multiprocessing but only for the daily master build (for performance reasons)
sed -i 's/"thread"/"thread", "multiprocessing"/g' pyproject.toml
fi
pytest --cov
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
Expand Down
3 changes: 3 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ docstring-quotes = "double"
quote-style = "single"

[tool.coverage.run]
source = ["src"]
omit = [
# ignore install scripts
"src/install.py",
Expand All @@ -116,6 +117,8 @@ omit = [
# ignore files only run inside docker
"src/plugins/analysis/*/docker/**",
]
concurrency = ["thread"]
parallel = true

[tool.coverage.report]
exclude_also = [
Expand Down

0 comments on commit a9a9a8e

Please sign in to comment.