Skip to content

Commit 42344f3

Browse files
committed
Beef up the test for get_option(paths)
1 parent fd43e35 commit 42344f3

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

tests/test_config.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,9 +342,22 @@ def test_tweaks_after_constructor(self):
342342
self.assertEqual(cov.get_option("run:data_file"), "fooey.dat")
343343

344344
def test_tweaks_paths_after_constructor(self):
345+
self.make_file(".coveragerc", """\
346+
[paths]
347+
first =
348+
/first/1
349+
/first/2
350+
351+
second =
352+
/second/a
353+
/second/b
354+
""")
355+
old_paths = OrderedDict()
356+
old_paths["first"] = ["/first/1", "/first/2"]
357+
old_paths["second"] = ["/second/a", "/second/b"]
345358
cov = coverage.Coverage()
346359
paths = cov.get_option("paths")
347-
self.assertEqual(paths, OrderedDict())
360+
self.assertEqual(paths, old_paths)
348361

349362
new_paths = OrderedDict()
350363
new_paths['magic'] = ['src', 'ok']

0 commit comments

Comments
 (0)