summaryrefslogtreecommitdiff
path: root/test/test_files.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/test_files.py')
-rw-r--r--test/test_files.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/test_files.py b/test/test_files.py
index 2f26c7b5..565bbaa4 100644
--- a/test/test_files.py
+++ b/test/test_files.py
@@ -120,6 +120,13 @@ class PathAliasesTest(CoverageTest):
aliases.add, "/ned/home/*/*/", "fooey"
)
+ def test_no_accidental_munging(self):
+ aliases = PathAliases()
+ aliases.add(r'c:\Zoo\boo', 'src/')
+ aliases.add('/home/ned$', 'src/')
+ self.assertEqual(aliases.map(r'c:\Zoo\boo\foo.py'), 'src/foo.py')
+ self.assertEqual(aliases.map(r'/home/ned$/foo.py'), 'src/foo.py')
+
def test_paths_are_os_corrected(self):
aliases = PathAliases()
aliases.add('/home/ned/*/src', './mysrc')