Skip to content

Commit fb52a9b

Browse files
csc-jmJoonatan Mäkinen
authored andcommitted
Add coverage check to gitlab ci
1 parent c88b002 commit fb52a9b

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

.coveragerc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ omit =
77
/usr/*
88
# omit this single file
99
swift_browser_ui/__init__.py
10+
# omit test files
11+
tests/*
1012

1113
[report]
1214
# Regexes for lines to exclude from consideration

.gitlab-ci.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@ backend-test:
4949
script:
5050
- pnpm --prefix swift_browser_ui_frontend docker-build
5151
- tox -e pytest
52+
- coverage run -m pytest tests/
53+
- coverage report --precision=1
54+
coverage: '/TOTAL.*\s+(\d+\%)/'
5255

5356
build-ci-image:
5457
stage: build

0 commit comments

Comments
 (0)