forked from ni/nimi-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtox-system_tests.ini
More file actions
70 lines (61 loc) · 3.41 KB
/
tox-system_tests.ini
File metadata and controls
70 lines (61 loc) · 3.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# Tox (http://tox.testrun.org/) is a tool for running tests
# in multiple virtualenvs. This configuration file will run the
# test suite on all supported python versions. To use it, "pip install tox"
# and then run "tox -c tox-system_tests.ini" from the driver directory. (generated/nidcpower)
[tox]
envlist = py{310,311,312,313}-nidcpower-system_tests, py313-nidcpower-coverage
skip_missing_interpreters=True
ignore_basepython_conflict=True
# We put the .tox directory outside of the Jenkins workspace so that it isn't wiped with the rest of the repo
toxworkdir = ../../../.tox
[testenv]
description =
nidcpower-system_tests: Run nidcpower system tests (requires NI-DCPower runtime to be installed)
nidcpower-coverage: Prepare coverage report for upload to codecov.io # upload handled by GitHub Actions
changedir =
nidcpower-system_tests: .
nidcpower-coverage: .
commands =
# --disable-pip-version-check prevents pip from telling us we need to upgrade pip, since we are doing that now
nidcpower-system_tests: python -m pip install --disable-pip-version-check --upgrade pip
nidcpower-system_tests: python -c "import nidcpower; nidcpower.print_diagnostic_information()"
nidcpower-system_tests: coverage run --rcfile=../../tools/coverage_system_tests.rc --source nidcpower --parallel-mode -m pytest ../../src/nidcpower/examples --junitxml=../junit/junit-nidcpower-{envname}-examples-{env:BITNESS:64}.xml {posargs}
nidcpower-system_tests: coverage run --rcfile=../../tools/coverage_system_tests.rc --source nidcpower --parallel-mode -m pytest ../../src/nidcpower/system_tests -c tox-system_tests.ini --junitxml=../junit/junit-nidcpower-{envname}-{env:BITNESS:64}.xml --durations=5 {posargs}
nidcpower-coverage: coverage combine --rcfile=../../tools/coverage_system_tests.rc ./
# Create the report to upload
nidcpower-coverage: coverage xml -i --rcfile=../../tools/coverage_system_tests.rc
# Display the coverage results
nidcpower-coverage: coverage report --rcfile=../../tools/coverage_system_tests.rc
deps =
nidcpower-system_tests: pytest
nidcpower-system_tests: coverage
nidcpower-system_tests: numpy
nidcpower-system_tests: hightime
nidcpower-system_tests: fasteners
nidcpower-system_tests: pytest-json
nidcpower-system_tests: .[grpc]
nidcpower-coverage: coverage
depends =
nidcpower-coverage: py{310,311,312,313}-nidcpower-system_tests
passenv =
GIT_BRANCH
GIT_COMMIT
BUILD_URL
BRANCH_NAME
JENKINS_URL
BUILD_NUMBER
[pytest]
addopts = --verbose
filterwarnings =
error::pytest.PytestUnhandledThreadExceptionWarning
norecursedirs = .* build dist CVS _darcs {arch} *.egg venv
junit_suite_name = nimi-python
junit_family = xunit1
markers = # Defines custom markers used by nidcpower system tests. Prevents PytestUnknownMarkWarning.
include_legacy_session: Include a legacy session in nidcpower system tests.
legacy_session_only: Exclude an independent channels session in nidcpower system tests.
resource_name: Overrides the default resource_name argument in the nidcpower session fixture.
channels: Overrides the default channels argument in the nidcpower session fixture.
reset: Overrides the default reset argument in the nidcpower session fixture.
options: Overrides the default options argument in the nidcpower session fixture.
independent_channels: Overrides the default independent_channels argument in the nidcpower session fixture.