[toypics] Separate user and video extraction (#2601)
This commit is contained in:
parent
55442a7812
commit
231f76b530
3 changed files with 59 additions and 29 deletions
|
@ -37,6 +37,7 @@ from youtube_dl.extractor import (
|
|||
GoogleSearchIE,
|
||||
GenericIE,
|
||||
TEDIE,
|
||||
ToypicsUserIE,
|
||||
)
|
||||
|
||||
|
||||
|
@ -269,5 +270,13 @@ class TestPlaylists(unittest.TestCase):
|
|||
self.assertEqual(result['title'], 'Who are the hackers?')
|
||||
self.assertTrue(len(result['entries']) >= 6)
|
||||
|
||||
def test_toypics_user(self):
|
||||
dl = FakeYDL()
|
||||
ie = ToypicsUserIE(dl)
|
||||
result = ie.extract('http://videos.toypics.net/Mikey')
|
||||
self.assertIsPlaylist(result)
|
||||
self.assertEqual(result['id'], 'Mikey')
|
||||
self.assertTrue(len(result['entries']) >= 17)
|
||||
|
||||
if __name__ == '__main__':
|
||||
unittest.main()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue