@@ -65,6 +65,7 @@ The tables below list all prerequisites along with the minimum required version
6565### Optional prerequisites for enhanced unit test features
6666| Prerequisite | Minimum Version |
6767| ------------------------------------------- | --------------- |
68+ | [ pytest-forked] ( https://pypi.python.org/pypi/pytest-forked ) | ` 0.2 ` |
6869| [ pytest-xdist] ( https://pypi.python.org/pypi/pytest-xdist ) | ` 1.15 ` |
6970| [ pytest-cov] ( https://pypi.python.org/pypi/pytest-cov ) | ` 1.8 ` |
7071
@@ -201,7 +202,7 @@ pip install -U pytest mock
201202pip install -U sphinx sphinx-rtd-theme
202203
203204# Install optional prerequisites for running unit tests in parallel and doing code coverage analysis
204- pip install -U pytest-xdist pytest-cov
205+ pip install -U pytest-xdist pytest-cov pytest-forked
205206```
206207
207208For doing cmd2 development, you actually do NOT want to have cmd2 installed as a Python package.
@@ -269,6 +270,13 @@ py.test -n4
269270```
270271where ` 4 ` should be replaced by the number of parallel threads you wish to run for testing.
271272
273+ If you have the ` pytest-forked ` pytest plugin (not avilable on Windows) for running tests in isolated formed processes,
274+ you can speed things up even further:
275+
276+ ``` shell
277+ py.test -nauto --forked
278+ ```
279+
272280#### Measuring code coverage
273281
274282Code coverage can be measured as follows:
@@ -390,11 +398,11 @@ how to do it.
390398
3913996 . Indicate what local testing you have done (e.g. what OS and version(s) of Python did you run the
392400 unit test suite with)
393-
401+
3944027 . Creating the PR causes our continuous integration (CI) systems to automatically run all of the
395403 unit tests on all supported OSes and all supported versions of Python. You should watch your PR
396404 to make sure that all unit tests pass on Both TravisCI (Linux) and AppVeyor (Windows).
397-
405+
3984068 . If any unit tests fail, you should look at the details and fix the failures. You can then push
399407 the fix to the same branch in your fork and the PR will automatically get updated and the CI system
400408 will automatically run all of the unit tests again.
0 commit comments