pytest-xstress
custom xdist scheduler that runs all tests infinitely.
Usage
$ pytest -nauto --dist loadgroup --xstress
xstress will switch the loadgroup scheduler to its own loadgroupstress scheduler that will run tests forever with its scheduling taking the group constraint into account. Such scheduling algorithm will try to be as fair as possible, which means running tests in an evenly distributed manner.
NOTE: The -n switch is important! Running xdist with only one process effectively runs without test distribution at all.
Example result:
(pytest-xstress-py3.12) ...@macbookpro pytest-xstress % python3 -m pytest test.py -n2 --dist loadgroup --xstress -v
============================= test session starts ==============================
platform darwin -- Python 3.12.2, pytest-8.2.1, pluggy-1.5.0 -- /Users/.../Library/Caches/pypoetry/virtualenvs/pytest-xstress-M8wNAFyb-py3.12/bin/python3
cachedir: .pytest_cache
rootdir: /Users/.../Development/pytest-xstress
configfile: pyproject.toml
plugins: publish-1.0.0, xstress-1.0.0, xdist-3.6.1
created: 2/2 workers
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
test.py::_test_single@a
[gw0] [100%] PASSED test.py::_test_single@a
...
Metadata
Release files for pytest-xstress 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pytest_xstress-1.0.1.tar.gz | 4.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pytest_xstress-1.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.5 kB
Release files / pytest_xstress-1.0.1.tar.gz
| Download URL | pytest_xstress-1.0.1.tar.gz |
|---|---|
| Size | 4.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
daf459481c01c27826b55ef4c87302beffb7e3fd163dc21edaea6faaf4202905
|
|
BLAKE2b-256 checksum How to use checksums |
7873fc151412afa5d6e5da718d56a3469c4ab958c5e49ffd940fb2af54155f92
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.1 CPython/3.10.12 Linux/5.15.146.1-microsoft-standard-WSL2
|
Release files / pytest_xstress-1.0.1-py3-none-any.whl
| Download URL | pytest_xstress-1.0.1-py3-none-any.whl |
|---|---|
| Size | 4.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9d4a5fd4d89a6a30cde615d747e65850b387f7743bc52529212255a665cc5645
|
|
BLAKE2b-256 checksum How to use checksums |
dd3daca1a64df0cd93cdf389ca3541d83c1fa736c798151a8b3d93bf628b07d2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.1 CPython/3.10.12 Linux/5.15.146.1-microsoft-standard-WSL2
|