Generate and use pytest XML reports
This generates XML reports when we run pytest through poe, and uploads them in the relevant CI stage. I've also ignored mypy cache files - I'm not sure why this hasn't been an issue before...
This commit is contained in:
parent
3e02fe4790
commit
e33e92b43a
3 changed files with 10 additions and 1 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -7,6 +7,9 @@
|
||||||
__pycache__/
|
__pycache__/
|
||||||
*.py[cod]
|
*.py[cod]
|
||||||
|
|
||||||
|
# Mypy cache
|
||||||
|
.mypy_cache*
|
||||||
|
|
||||||
# C extensions
|
# C extensions
|
||||||
*.so
|
*.so
|
||||||
|
|
||||||
|
|
@ -45,6 +48,7 @@ htmlcov/
|
||||||
.cache
|
.cache
|
||||||
nosetests.xml
|
nosetests.xml
|
||||||
coverage.xml
|
coverage.xml
|
||||||
|
pytest_report.xml
|
||||||
|
|
||||||
# Translations
|
# Translations
|
||||||
*.mo
|
*.mo
|
||||||
|
|
|
||||||
|
|
@ -102,6 +102,11 @@ pytest:
|
||||||
- tags
|
- tags
|
||||||
- web
|
- web
|
||||||
|
|
||||||
|
artifacts:
|
||||||
|
when: always
|
||||||
|
reports:
|
||||||
|
junit: pytest_report.xml
|
||||||
|
|
||||||
openapi:
|
openapi:
|
||||||
stage: testing
|
stage: testing
|
||||||
image: python:3.7
|
image: python:3.7
|
||||||
|
|
|
||||||
|
|
@ -44,7 +44,7 @@ black_check = "black --check ."
|
||||||
isort = "isort openflexure_microscope"
|
isort = "isort openflexure_microscope"
|
||||||
pylint = "pylint openflexure_microscope"
|
pylint = "pylint openflexure_microscope"
|
||||||
mypy = "mypy --cobertura-xml-report openflexure_microscope openflexure_microscope"
|
mypy = "mypy --cobertura-xml-report openflexure_microscope openflexure_microscope"
|
||||||
test = "pytest ."
|
test = "pytest . --junitxml=pytest_report.xml"
|
||||||
serve = "python -m openflexure_microscope.api.app"
|
serve = "python -m openflexure_microscope.api.app"
|
||||||
|
|
||||||
format = ["black", "isort"]
|
format = ["black", "isort"]
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue