Personal GitHub site
To run PyTest on multiple CPU cores, perform the following steps:
pytest-xdist
pytest -n auto
. With this call, PyTest will spawn a number of workers processes equal to the number of available CPUs, and distribute the tests randomly across them.For a more refined distribution of the tests, see some of the following options:
pytest -n auto --dist loadscope
pytest -n auto --dist loadfile