aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authordst <dstftw@gmail.com>2013-12-02 20:10:19 +0700
committerdst <dstftw@gmail.com>2013-12-02 20:10:19 +0700
commit5270d8cb1389a9b26fa698137bf4861d4bab6a25 (patch)
tree32995b993d2f2dcdfbd1b75416bbe5007bd61a5b /test
parent55a10eab48776197245d3d87b86195f182d8d82a (diff)
Added extractors for smotri.com
Diffstat (limited to 'test')
-rw-r--r--test/test_playlists.py22
1 files changed, 21 insertions, 1 deletions
diff --git a/test/test_playlists.py b/test/test_playlists.py
index 13a6f4b2f..00c950109 100644
--- a/test/test_playlists.py
+++ b/test/test_playlists.py
@@ -22,7 +22,9 @@ from youtube_dl.extractor import (
LivestreamIE,
NHLVideocenterIE,
BambuserChannelIE,
- BandcampAlbumIE
+ BandcampAlbumIE,
+ SmotriCommunityIE,
+ SmotriUserIE
)
@@ -119,6 +121,24 @@ class TestPlaylists(unittest.TestCase):
self.assertIsPlaylist(result)
self.assertEqual(result['title'], u'Nightmare Night EP')
self.assertTrue(len(result['entries']) >= 4)
+
+ def test_smotri_community(self):
+ dl = FakeYDL()
+ ie = SmotriCommunityIE(dl)
+ result = ie.extract('http://smotri.com/community/video/kommuna')
+ self.assertIsPlaylist(result)
+ self.assertEqual(result['id'], u'kommuna')
+ self.assertEqual(result['title'], u'КПРФ')
+ self.assertTrue(len(result['entries']) >= 4)
+
+ def test_smotri_user(self):
+ dl = FakeYDL()
+ ie = SmotriUserIE(dl)
+ result = ie.extract('http://smotri.com/user/inspector')
+ self.assertIsPlaylist(result)
+ self.assertEqual(result['id'], u'inspector')
+ self.assertEqual(result['title'], u'Inspector')
+ self.assertTrue(len(result['entries']) >= 9)
if __name__ == '__main__':
unittest.main()