[youtube:playlist] Recognize ‘top tracks’ urls (closes #2332)

The list parameter starts with ‘MC’ and can have more characters after it, including dots
This commit is contained in:
Jaime Marquínez Ferrándiz 2014-02-06 19:46:26 +01:00
parent bf3a2fe923
commit d67cc9fa7c
3 changed files with 16 additions and 8 deletions

View file

@ -117,6 +117,13 @@ class TestYoutubeLists(unittest.TestCase):
original_video = entries[0]
self.assertEqual(original_video['id'], 'rjFaenf1T-Y')
def test_youtube_toptracks(self):
dl = FakeYDL()
ie = YoutubePlaylistIE(dl)
result = ie.extract('https://www.youtube.com/playlist?list=MCUS')
entries = result['entries']
self.assertEqual(len(entries), 100)
def test_youtube_toplist(self):
dl = FakeYDL()
ie = YoutubeTopListIE(dl)