diff options
Diffstat (limited to 'coverage/codeunit.py')
-rw-r--r-- | coverage/codeunit.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/coverage/codeunit.py b/coverage/codeunit.py index 6312efe2..a0da1a71 100644 --- a/coverage/codeunit.py +++ b/coverage/codeunit.py @@ -6,16 +6,18 @@ from coverage.backward import string_class, StringIO from coverage.misc import CoverageException -def code_unit_factory(morfs, file_locator, omit_prefixes=None, include_prefixes=None): +def code_unit_factory( + morfs, file_locator, omit_prefixes=None, include_prefixes=None + ): """Construct a list of CodeUnits from polymorphic inputs. `morfs` is a module or a filename, or a list of same. + `file_locator` is a FileLocator that can help resolve filenames. - `omit_prefixes` is a list of prefixes. CodeUnits that match those prefixes - will be omitted from the list. - `include_prefixes` is a list of prefixes. Only CodeUnits that match those prefixes - will be included in the list. - You are required to pass at most one of `omit_prefixes` and `include_prefixes`. + + `include_prefixes` is a list of prefixes. Only CodeUnits that match those + prefixes will be included in the list. `omit_prefixes` is a list of + prefixes to omit from the list. Returns a list of CodeUnit objects. |