test: Fix playlist plugin path handling for Windows compatibility
@@ -87,7 +87,10 @@ class PlaylistTest(unittest.TestCase, helper.TestHelper):
]))
def test_query_path(self):
- q = u'playlist:{0}/test.m3u'.format(self.playlist_dir)
+ q = u'playlist:{0}'.format(os.path.join(
+ self.playlist_dir,
+ 'test.m3u',
+ ))
results = self.lib.items(q)
self.assertEqual(set([i.title for i in results]), set([
u'some item',
@@ -100,7 +103,10 @@ class PlaylistTest(unittest.TestCase, helper.TestHelper):
self.assertEqual(set(results), set())
def test_query_path_nonexisting(self):
- q = u'playlist:{0}/nonexisting.m3u'.format(self.playlist_dir)
+ q = u'playlist:{0}'.format(os.path.join(
+ self.playlist_dir,
+ 'nonexisting.m3u',
+ ))
results = self.lib.items(q)
self.assertEqual(set(results), set())
