mirror of
https://github.com/l1ving/youtube-dl
synced 2025-03-11 09:37:23 +08:00
adding youtube user
This commit is contained in:
parent
c9128b353d
commit
b2401d8e66
@ -10,6 +10,7 @@ from youtube_dl.InfoExtractors import MetacafeIE, BlipTVIE
|
||||
from youtube_dl.InfoExtractors import XVideosIE, VimeoIE
|
||||
from youtube_dl.InfoExtractors import SoundcloudIE, StanfordOpenClassroomIE
|
||||
from youtube_dl.InfoExtractors import CollegeHumorIE, XNXXIE
|
||||
from youtube_dl.InfoExtractors import YoutubeUserIE
|
||||
|
||||
|
||||
class DownloadTest(unittest.TestCase):
|
||||
@ -21,6 +22,8 @@ class DownloadTest(unittest.TestCase):
|
||||
YOUTUBE_URL = "http://www.youtube.com/watch?v=BaW_jenozKc"
|
||||
YOUTUBE_FILE = "BaW_jenozKc.mp4"
|
||||
|
||||
YOUTUBEUSER_URL = "http://www.youtube.com/user/phihag"
|
||||
|
||||
DAILYMOTION_MD5 = "d363a50e9eb4f22ce90d08d15695bb47"
|
||||
DAILYMOTION_URL = "http://www.dailymotion.com/video/x33vw9_tutoriel-de-youtubeur-dl-des-video_tech"
|
||||
DAILYMOTION_FILE = "x33vw9.mp4"
|
||||
@ -70,6 +73,15 @@ class DownloadTest(unittest.TestCase):
|
||||
self.assertTrue(os.path.exists(DownloadTest.YOUTUBE_FILE))
|
||||
self.assertEqual(os.path.getsize(DownloadTest.YOUTUBE_FILE), DownloadTest.YOUTUBE_SIZE)
|
||||
|
||||
def test_youtubeuser(self):
|
||||
with open(DownloadTest.PARAMETERS_FILE) as f:
|
||||
fd = FileDownloader(json.load(f))
|
||||
fd.add_info_extractor(YoutubeUserIE())
|
||||
fd.add_info_extractor(YoutubeIE())
|
||||
fd.download([DownloadTest.YOUTUBEUSER_URL])
|
||||
self.assertTrue(os.path.exists(DownloadTest.YOUTUBE_FILE))
|
||||
self.assertEqual(os.path.getsize(DownloadTest.YOUTUBE_FILE), DownloadTest.YOUTUBE_SIZE)
|
||||
|
||||
def test_dailymotion(self):
|
||||
with open(DownloadTest.PARAMETERS_FILE) as f:
|
||||
fd = FileDownloader(json.load(f))
|
||||
@ -120,7 +132,6 @@ class DownloadTest(unittest.TestCase):
|
||||
|
||||
def test_vimeo2(self):
|
||||
#skipped for the moment produce an error
|
||||
return
|
||||
with open(DownloadTest.PARAMETERS_FILE) as f:
|
||||
fd = FileDownloader(json.load(f))
|
||||
fd.add_info_extractor(VimeoIE())
|
||||
|
Loading…
x
Reference in New Issue
Block a user