diff --git a/test/rsrc/unicode_path_sep.mp3 b/test/rsrc/unicode_path_sep.mp3 new file mode 100644 index 000000000..fa543b7fb Binary files /dev/null and b/test/rsrc/unicode_path_sep.mp3 differ diff --git a/test/test_library.py b/test/test_library.py index 26c78c99d..a2f399593 100644 --- a/test/test_library.py +++ b/test/test_library.py @@ -416,11 +416,11 @@ class DestinationTest(_common.TestCase): def test_asciify_and_replace(self): config['asciify_paths'] = True - self.lib.replacements = [(re.compile(u'"'), u'q')] + self.lib.replacements = [(re.compile(u'"'), u'q'), (re.compile(os.path.sep), config['path_sep_replace'].get())] self.lib.directory = b'lib' self.lib.path_formats = [(u'default', u'$title')] - self.i.title = u'\u201c\u00f6\u2014\u00cf\u201d' - self.assertEqual(self.i.destination(), np('lib/qo--Iq')) + self.i.title = u'\u201c\xa2\u00f6\u2014\u00cf\xbd\u201d' + self.assertEqual(self.i.destination(), np('lib/qC_o--I1_2q')) def test_destination_with_replacements(self): self.lib.directory = b'base'