File: subprocess.rst

package info (click to toggle)
pytest-xdist 3.8.0-3
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 684 kB
  • sloc: python: 5,497; makefile: 7; sh: 5
file content (16 lines) | stat: -rw-r--r-- 514 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
Running tests in a Python subprocess
====================================

To instantiate a ``python3.9`` subprocess and send tests to it, you may type::

    pytest -d --tx popen//python=python3.9

This will start a subprocess which is run with the ``python3.9``
Python interpreter, found in your system binary lookup path.

If you prefix the --tx option value like this::

    --tx 3*popen//python=python3.9

then three subprocesses would be created and tests
will be load-balanced across these three processes.