diff options
author | Ismael Mejia <iemejia@gmail.com> | 2013-09-11 14:26:48 +0200 |
---|---|---|
committer | Ismael Mejia <iemejia@gmail.com> | 2013-09-11 14:26:48 +0200 |
commit | cf1dd0c59e8ff4c66130bc47954c415be5db8cc3 (patch) | |
tree | a39741b945c88b9a7b3bc14c94efdc6fe7b3302f /test/test_all_urls.py | |
parent | 72836fcee453386f4f16325c5b8fa4c1ba1bb442 (diff) | |
parent | 22c8b525458c8203c0709a523c646b8d152f03b0 (diff) |
Merge branch 'master' into subtitles_rework
Diffstat (limited to 'test/test_all_urls.py')
-rw-r--r-- | test/test_all_urls.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/test/test_all_urls.py b/test/test_all_urls.py index 5d8d93e0e..99fc7bd28 100644 --- a/test/test_all_urls.py +++ b/test/test_all_urls.py @@ -72,10 +72,13 @@ class TestAllURLsMatching(unittest.TestCase): self.assertTrue(JustinTVIE.suitable(u"http://www.twitch.tv/tsm_theoddone/c/2349361")) def test_youtube_extract(self): - self.assertEqual(YoutubeIE()._extract_id('http://www.youtube.com/watch?&v=BaW_jenozKc'), 'BaW_jenozKc') - self.assertEqual(YoutubeIE()._extract_id('https://www.youtube.com/watch?&v=BaW_jenozKc'), 'BaW_jenozKc') - self.assertEqual(YoutubeIE()._extract_id('https://www.youtube.com/watch?feature=player_embedded&v=BaW_jenozKc'), 'BaW_jenozKc') - self.assertEqual(YoutubeIE()._extract_id('https://www.youtube.com/watch_popup?v=BaW_jenozKc'), 'BaW_jenozKc') + assertExtractId = lambda url, id: self.assertEqual(YoutubeIE()._extract_id(url), id) + assertExtractId('http://www.youtube.com/watch?&v=BaW_jenozKc', 'BaW_jenozKc') + assertExtractId('https://www.youtube.com/watch?&v=BaW_jenozKc', 'BaW_jenozKc') + assertExtractId('https://www.youtube.com/watch?feature=player_embedded&v=BaW_jenozKc', 'BaW_jenozKc') + assertExtractId('https://www.youtube.com/watch_popup?v=BaW_jenozKc', 'BaW_jenozKc') + assertExtractId('http://www.youtube.com/watch?v=BaW_jenozKcsharePLED17F32AD9753930', 'BaW_jenozKc') + assertExtractId('BaW_jenozKc', 'BaW_jenozKc') def test_no_duplicates(self): ies = gen_extractors() |