aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>2013-09-21 12:45:53 +0200
committerJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>2013-09-21 12:45:53 +0200
commit39baacc49f323adc639d502d38a016ebd63acd75 (patch)
treeedf18fc76bac63faca27ed4b2a737fab88fc0e67 /test
parent3a1d48d6de0159807ff57b2cec6766cbfd400f00 (diff)
[dailymotion] Add an extractor for users (closes #1476)
Diffstat (limited to 'test')
-rw-r--r--test/test_playlists.py16
1 files changed, 15 insertions, 1 deletions
diff --git a/test/test_playlists.py b/test/test_playlists.py
index d079a4f23..e22054d69 100644
--- a/test/test_playlists.py
+++ b/test/test_playlists.py
@@ -1,4 +1,5 @@
#!/usr/bin/env python
+# encoding: utf-8
import sys
import unittest
@@ -8,7 +9,13 @@ import json
import os
sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
-from youtube_dl.extractor import DailymotionPlaylistIE, VimeoChannelIE, UstreamChannelIE, SoundcloudUserIE
+from youtube_dl.extractor import (
+ DailymotionPlaylistIE,
+ DailymotionUserIE,
+ VimeoChannelIE,
+ UstreamChannelIE,
+ SoundcloudUserIE,
+)
from youtube_dl.utils import *
from helper import FakeYDL
@@ -25,6 +32,13 @@ class TestPlaylists(unittest.TestCase):
self.assertIsPlaylist(result)
self.assertEqual(result['title'], u'SPORT')
self.assertTrue(len(result['entries']) > 20)
+ def test_dailymotion_user(self):
+ dl = FakeYDL()
+ ie = DailymotionUserIE(dl)
+ result = ie.extract('http://www.dailymotion.com/user/generation-quoi/')
+ self.assertIsPlaylist(result)
+ self.assertEqual(result['title'], u'Génération Quoi')
+ self.assertTrue(len(result['entries']) >= 26)
def test_vimeo_channel(self):
dl = FakeYDL()