From 851cad1819958893ac44208510e8d3ab86c0d77d Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Sat, 23 Jan 2016 14:25:17 -0500 Subject: Do a better job with sources in the XML report --- tests/test_xml.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'tests') diff --git a/tests/test_xml.py b/tests/test_xml.py index 60cdd71d..357c4ead 100644 --- a/tests/test_xml.py +++ b/tests/test_xml.py @@ -271,6 +271,16 @@ class XmlPackageStructureTest(XmlTestHelpers, CoverageTest): """) + def test_source_prefix(self): + # https://bitbucket.org/ned/coveragepy/issues/465 + self.make_file("src/mod.py", "print(17)") + cov = coverage.Coverage(source=["src"]) + self.start_import_stop(cov, "mod", modfile="src/mod.py") + self.assert_package_and_class_tags(cov, """\ + + + """) + def re_lines(text, pat): """Return a list of lines that match `pat` in the string `text`.""" -- cgit v1.2.1