From a1bcb2f1b57efedb78d1f8861202dcceba99c884 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Mon, 25 Oct 2010 17:28:33 -0400 Subject: Clarify some docs. --- doc/subprocess.rst | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'doc/subprocess.rst') diff --git a/doc/subprocess.rst b/doc/subprocess.rst index 383c797f..bcf50445 100644 --- a/doc/subprocess.rst +++ b/doc/subprocess.rst @@ -26,6 +26,14 @@ multiple coverage.py runs will each write their data to a distinct file. Configuring Python for subprocess coverage ------------------------------------------ +To measure coverage in subprocesses, you have to do two things: set a value for +the ``COVERAGE_PROCESS_START`` environment variable, and then invoke +:func:`coverage.process_startup`. + +How you set ``COVERAGE_PROCESS_START`` depends on the details of how you create +subprocesses. As long as the environment variable is visible in your subprocess, +it will work. + You can configure your Python installation to invoke the ``process_startup`` function in two ways: -- cgit v1.2.1