Commit a34a46b5 by rfkelly0

add some simple unicode path tests

parent abf58c24
...@@ -20,6 +20,7 @@ class TestPathFunctions(unittest.TestCase): ...@@ -20,6 +20,7 @@ class TestPathFunctions(unittest.TestCase):
("a/b/c", "a/b/c"), ("a/b/c", "a/b/c"),
("a/b/../c/", "a/c"), ("a/b/../c/", "a/c"),
("/","/"), ("/","/"),
(u"a/\N{GREEK SMALL LETTER BETA}\\c",u"a/\N{GREEK SMALL LETTER BETA}/c"),
] ]
for path, result in tests: for path, result in tests:
self.assertEqual(normpath(path), result) self.assertEqual(normpath(path), result)
...@@ -40,6 +41,7 @@ class TestPathFunctions(unittest.TestCase): ...@@ -40,6 +41,7 @@ class TestPathFunctions(unittest.TestCase):
("a/b", "./d", "e", "a/b/d/e"), ("a/b", "./d", "e", "a/b/d/e"),
("/", "/", "/"), ("/", "/", "/"),
("/", "", "/"), ("/", "", "/"),
(u"a/\N{GREEK SMALL LETTER BETA}","c",u"a/\N{GREEK SMALL LETTER BETA}/c"),
] ]
for testpaths in tests: for testpaths in tests:
paths = testpaths[:-1] paths = testpaths[:-1]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment