1
1
# This is work in progress, testing workflow in local/CI is gradually being transferred to tox
2
2
3
3
# Usage instructions:
4
+
4
5
# `tox` will run all tests sequentially, `tox --parallel` will run all tests in parallel (much faster).
5
6
# Run specific selection of tests with `tox -e pretest,<list-of-tests>,posttest` e.g., `tox -e pretest,test-api,test-launcher,posttest`
6
7
# `--parallel` flag can be passed when running specific selections.
7
8
9
+ # For packaging, build wheels for specific platform with `tox -e build-wheel -- <platform_name>`.
10
+ # If `tox -e build-wheel` is run without passing a platform, tox will automatically build the ffl wheels based on the operating system
11
+ # on which it is executing: windows -> "win_amd64", linux -> "manylinux_2_17_x86_64", mac -> "any"
12
+
8
13
[tox]
9
14
description = Default tox environment list and core configurations
10
15
11
- # List all tests to run in parallel or sequential mode here
12
- # So invocation can be specified as `tox`/`tox --parallel` to run all tests in sequential/parallel mode
13
16
envlist = pretest,test-{api,launcher,server,local_server,multi_server,remote_workflow,remote_operator,workflow,service,operators},posttest
14
17
15
18
isolated_build_env = build
@@ -24,17 +27,6 @@ pass_env =
24
27
ANSYSLMD_LICENSE_FILE
25
28
AWP_ROOT242
26
29
27
- package = external # To allow custom wheel builds
28
-
29
- [testenv:build_external]
30
- description = Environment for custom build of package wheels, solves PyDPF custom wheel building requirement
31
-
32
- package_glob = {toxinidir}{/}dist{/}ansys_dpf_core*
33
-
34
- # {on_platform} substitution to automatically detect os type.
35
- commands =
36
- python .ci/build_wheel.py -p {on_platform} -w
37
-
38
30
[testenv:pretest]
39
31
description = Environment to kill servers and organize test files prior to testing
40
32
@@ -115,4 +107,12 @@ deps =
115
107
-r requirements/requirements_test.txt
116
108
117
109
commands =
118
- pytest {env:PYTEST_PYTHON_FILES} {env:DEBUG} {env:COVERAGE} {env:RERUNS} {env:JUNITXML}
110
+ pytest {env:PYTEST_PYTHON_FILES} {env:DEBUG} {env:COVERAGE} {env:RERUNS} {env:JUNITXML}
111
+
112
+ [testenv:build-wheel]
113
+ description = Environment for custom build of package wheels
114
+
115
+ skip_install = True
116
+
117
+ commands =
118
+ python .ci/build_wheel.py -p {posargs:{on_platform}} -w
0 commit comments