Skip to content

Commit 5db303f

Browse files
authored
feat: implemented changes (#2012)
1 parent a1bfa92 commit 5db303f

File tree

2 files changed

+16
-15
lines changed

2 files changed

+16
-15
lines changed

.ci/build_wheel.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515
"win": "win_amd64",
1616
"manylinux1": "manylinux1_x86_64",
1717
"manylinux_2_17": "manylinux_2_17_x86_64",
18-
"linux": "manylinux_2_17_x86_64", # Accommodate tox.ini platform substitutions
18+
# Accommodate tox.ini automatic platform substitutions
19+
"linux": "manylinux_2_17_x86_64",
1920
"win32": "win_amd64",
2021
"darwin": "any",
2122
}

tox.ini

+14-14
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
11
# This is work in progress, testing workflow in local/CI is gradually being transferred to tox
22

33
# Usage instructions:
4+
45
# `tox` will run all tests sequentially, `tox --parallel` will run all tests in parallel (much faster).
56
# Run specific selection of tests with `tox -e pretest,<list-of-tests>,posttest` e.g., `tox -e pretest,test-api,test-launcher,posttest`
67
# `--parallel` flag can be passed when running specific selections.
78

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+
813
[tox]
914
description = Default tox environment list and core configurations
1015

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
1316
envlist = pretest,test-{api,launcher,server,local_server,multi_server,remote_workflow,remote_operator,workflow,service,operators},posttest
1417

1518
isolated_build_env = build
@@ -24,17 +27,6 @@ pass_env =
2427
ANSYSLMD_LICENSE_FILE
2528
AWP_ROOT242
2629

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-
3830
[testenv:pretest]
3931
description = Environment to kill servers and organize test files prior to testing
4032

@@ -115,4 +107,12 @@ deps =
115107
-r requirements/requirements_test.txt
116108

117109
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

Comments
 (0)