diff options
author | pukkandan <pukkandan.ytdlp@gmail.com> | 2022-07-08 16:53:05 +0530 |
---|---|---|
committer | pukkandan <pukkandan.ytdlp@gmail.com> | 2022-08-02 01:08:16 +0530 |
commit | f2e8dbcc0067fb16b632de1984e622a8e99d9d8f (patch) | |
tree | bfd8af8427fef0a482189179a39ee18a4627b987 /yt_dlp/extractor/youtube.py | |
parent | 8f97a15d1c7ebc10d0b51ce24632ac17b34a5f69 (diff) | |
download | hypervideo-pre-f2e8dbcc0067fb16b632de1984e622a8e99d9d8f.tar.lz hypervideo-pre-f2e8dbcc0067fb16b632de1984e622a8e99d9d8f.tar.xz hypervideo-pre-f2e8dbcc0067fb16b632de1984e622a8e99d9d8f.zip |
[extractor, test] Basic framework for embed tests (#4307)
and split download tests so they can be more easily run in CI
Authored by: coletdjnz
Diffstat (limited to 'yt_dlp/extractor/youtube.py')
-rw-r--r-- | yt_dlp/extractor/youtube.py | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/yt_dlp/extractor/youtube.py b/yt_dlp/extractor/youtube.py index fb23afbad..4dc8e79ac 100644 --- a/yt_dlp/extractor/youtube.py +++ b/yt_dlp/extractor/youtube.py @@ -2266,6 +2266,42 @@ class YoutubeIE(YoutubeBaseInfoExtractor): } ] + _WEBPAGE_TESTS = [ + # YouTube <object> embed + { + 'url': 'http://www.improbable.com/2017/04/03/untrained-modern-youths-and-ancient-masters-in-selfie-portraits/', + 'md5': '873c81d308b979f0e23ee7e620b312a3', + 'info_dict': { + 'id': 'msN87y-iEx0', + 'ext': 'mp4', + 'title': 'Feynman: Mirrors FUN TO IMAGINE 6', + 'upload_date': '20080526', + 'description': 'md5:873c81d308b979f0e23ee7e620b312a3', + 'uploader': 'Christopher Sykes', + 'uploader_id': 'ChristopherJSykes', + 'age_limit': 0, + 'tags': ['feynman', 'mirror', 'science', 'physics', 'imagination', 'fun', 'cool', 'puzzle'], + 'channel_id': 'UCCeo--lls1vna5YJABWAcVA', + 'playable_in_embed': True, + 'thumbnail': 'https://i.ytimg.com/vi/msN87y-iEx0/hqdefault.jpg', + 'like_count': int, + 'comment_count': int, + 'channel': 'Christopher Sykes', + 'live_status': 'not_live', + 'channel_url': 'https://www.youtube.com/channel/UCCeo--lls1vna5YJABWAcVA', + 'availability': 'public', + 'duration': 195, + 'view_count': int, + 'categories': ['Science & Technology'], + 'channel_follower_count': int, + 'uploader_url': 'http://www.youtube.com/user/ChristopherJSykes', + }, + 'params': { + 'skip_download': True, + } + }, + ] + @classmethod def suitable(cls, url): from ..utils import parse_qs |