summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2018-02-10 10:15:04 -0500
committerNed Batchelder <ned@nedbatchelder.com>2018-02-10 10:15:04 -0500
commitccb6896d0717c83147a43f4e25f7f76c9a8807e4 (patch)
tree31a2590b5e1981d40d21a1132f6cd5e3f9a46b34 /tests
parentcbfefaeed86e276677d4c0aa56c5897eb67dcf10 (diff)
downloadpython-coveragepy-ccb6896d0717c83147a43f4e25f7f76c9a8807e4.tar.gz
Oops, omitting inside a source package didn't work. Now it does. #638
Diffstat (limited to 'tests')
-rw-r--r--tests/test_api.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_api.py b/tests/test_api.py
index b5fcd53..b461c50 100644
--- a/tests/test_api.py
+++ b/tests/test_api.py
@@ -615,6 +615,13 @@ class SourceOmitIncludeTest(OmitIncludeTestsMixin, CoverageTest):
self.filenames_not_in(lines, "p1b")
self.assertEqual(lines['p1c'], 0)
+ def test_source_package_as_package_part_omitted(self):
+ # https://bitbucket.org/ned/coveragepy/issues/638/run-omit-is-ignored-since-45
+ lines = self.coverage_usepkgs(source=["pkg1"], omit=["*/p1b.py"])
+ self.filenames_in(lines, "p1a")
+ self.filenames_not_in(lines, "p1b")
+ self.assertEqual(lines['p1c'], 0)
+
class ReportIncludeOmitTest(OmitIncludeTestsMixin, CoverageTest):
"""Tests of the report include/omit functionality."""