Skip to content
Snippets Groups Projects
Commit 541eff79 authored by payno's avatar payno
Browse files

Merge branch 'pytest_ns_packge' into 'main'

pytest and native namespace packages

See merge request workflow/ewoksapps/est!138
parents 52559a78 1cca8abf
No related branches found
No related tags found
No related merge requests found
......@@ -16,40 +16,31 @@ flake8_nb:
test-3.8:
extends: .test-3.8_glx
script:
- python -m pip install --pre -e .[test]
- python -m pytest ${PYTEST_OPTIONS} ${IGNORE_WARNINGS} .
timeout: 20m
variables:
PYTEST_OPTIONS: "--import-mode=importlib --cov=./src -v"
PYTEST_WARNINGS: "-W error ${IGNORE_WARNINGS}"
PIP_INSTALL_OPTIONS: "--pre -e" # because of --import-mode=importlib"
test-3.8-minimal:
extends: .test-3.8_glx
script:
- python -m pip install --pre .[test]
- python -m pytest ${PYTEST_OPTIONS} ${IGNORE_WARNINGS} .
timeout: 20m
variables:
PYTEST_OPTIONS: "--import-mode=importlib"
PYTEST_WARNINGS: "-W error ${IGNORE_WARNINGS}"
PYTEST_COV: ""
test-3.8-pymca:
extends: .test-3.8_glx
script:
- python -m pip install --pre .[test_no_larh_or_pymca,pymca]
- python -m pytest ${PYTEST_OPTIONS} ${IGNORE_WARNINGS} .
timeout: 20m
variables:
PYTEST_OPTIONS: "--import-mode=importlib"
PYTEST_WARNINGS: "-W error ${IGNORE_WARNINGS}"
PYTEST_COV: ""
test-3.8-larch:
extends: .test-3.8_glx
script:
- python -m pip install --pre .[test_no_larh_or_pymca,larch]
- python -m pytest ${PYTEST_OPTIONS} ${IGNORE_WARNINGS} .
timeout: 20m
variables:
PYTEST_OPTIONS: "--import-mode=importlib"
PYTEST_WARNINGS: "-W error ${IGNORE_WARNINGS}"
PYTEST_COV: ""
test-3.8-larch-example:
extends: .test-3.8_glx
......@@ -63,7 +54,6 @@ build_sdist:
test_sdist-3.9:
extends: .test_sdist-3.9_glx
variables:
PYTEST_OPTIONS: "--import-mode=importlib -v"
PYTEST_WARNINGS: "-W error ${IGNORE_WARNINGS}"
build_doc:
......
......@@ -3,4 +3,8 @@ requires = [
"setuptools>=46.4<63",
"wheel",
]
build-backend = "setuptools.build_meta"
\ No newline at end of file
build-backend = "setuptools.build_meta"
[tool.pytest.ini_options]
# consider_namespace_packages = true # for pytest>=8.1
addopts = "--import-mode=importlib" # for all pytest versions, pytest-cov needs `pip install -e .`
......@@ -102,5 +102,4 @@ max-line-length = 88
[coverage:run]
omit =
setup.py
*/tests/*
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment