diff options
| author | Ned Batchelder <ned@nedbatchelder.com> | 2021-10-18 07:02:35 -0400 |
|---|---|---|
| committer | Ned Batchelder <ned@nedbatchelder.com> | 2021-10-18 07:02:35 -0400 |
| commit | 50a0e37ad2e7a5ec655a797f0688f616c8b1a56f (patch) | |
| tree | 4bc193ea76035b5524355338fc112610746d74ed /doc/cmd.rst | |
| parent | 6352398dcd822b761a552d9f02df6fc96ce3cbeb (diff) | |
| download | python-coveragepy-git-50a0e37ad2e7a5ec655a797f0688f616c8b1a56f.tar.gz | |
docs: clarify how --source affects reporting commands. #1159
Diffstat (limited to 'doc/cmd.rst')
| -rw-r--r-- | doc/cmd.rst | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/doc/cmd.rst b/doc/cmd.rst index 1a54043d..2ce7cc13 100644 --- a/doc/cmd.rst +++ b/doc/cmd.rst @@ -103,6 +103,13 @@ but before the program invocation:: $ coverage run --source=dir1,dir2 my_program.py arg1 arg2 $ coverage run --source=dir1,dir2 -m packagename.modulename arg1 arg2 +.. note:: + Specifying ``--source`` on the ``coverage run`` command line won't affect + subsequent reporting commands like ``coverage xml``. Use the + :ref:`source <config_run_source>` setting in the configuration file to apply + the setting uniformly to all commands. + + Coverage.py can measure multi-threaded programs by default. If you are using more exotic concurrency, with the `multiprocessing`_, `greenlet`_, `eventlet`_, or `gevent`_ libraries, then coverage.py will get very confused. Use the |
