pytest-mproc

pytest parallelization based on multiprocessing for less overhead


License
BSD-2-Clause
Install
pip install pytest-mproc==1.0.4

Documentation

Intoduction
-----------

Welcome to pytest-mproc, a plugin for pytest to run distributed testing via multiprocessing.  This manner
of distributed testing has several advantages, including much more efficient execution.

xdist works for cases perhaps where there are large number of tests, but the cost of overhead in using rsync and
overall implementation prevents realization of test-execution-time gains that one might hope for.

To use with pytest, you use the -C or equivalently --cores argument to specify how many cores to run on:

% pytest --cores 3 [remaining arguments]

or to specify use of all available cores:

% pytest --cores auto [remaining argumnets]

NOTES on testing this product
-----------------------------
To test proper error reporting, test_some_alg3 should always FAIL.  This may seem odd, but for now we are testing the
test reporting system and the test deliberately asserts on False to see that it shows up in the test report as such.