aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2015-01-24 16:11:40 +0600
committerSergey M․ <dstftw@gmail.com>2015-01-24 16:11:40 +0600
commitfc2d6abfe7e7a216825296001b889e5455e0412f (patch)
treead9aa627cae1fa320e6330e7d4b0397450e67f29 /youtube_dl/extractor
parent27de5625d4b75789afd288beb581bd54bc8bd623 (diff)
[videott] Improve _VALID_URL and add test
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r--youtube_dl/extractor/videott.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/youtube_dl/extractor/videott.py b/youtube_dl/extractor/videott.py
index 6f8084140..ececc7ee0 100644
--- a/youtube_dl/extractor/videott.py
+++ b/youtube_dl/extractor/videott.py
@@ -13,9 +13,9 @@ from ..utils import (
class VideoTtIE(InfoExtractor):
ID_NAME = 'video.tt'
IE_DESC = 'video.tt - Your True Tube'
- _VALID_URL = r'http://(?:www\.)?video\.tt/(?:video\/|embed\/|watch_video\.php\?v=)(?P<id>[\da-zA-Z]{9})'
+ _VALID_URL = r'http://(?:www\.)?video\.tt/(?:(?:video|embed)/|watch_video\.php\?v=)(?P<id>[\da-zA-Z]{9})'
- _TEST = {
+ _TESTS = [{
'url': 'http://www.video.tt/watch_video.php?v=amd5YujV8',
'md5': 'b13aa9e2f267effb5d1094443dff65ba',
'info_dict': {
@@ -26,7 +26,10 @@ class VideoTtIE(InfoExtractor):
'upload_date': '20130827',
'uploader': 'joseph313',
}
- }
+ }, {
+ 'url': 'http://video.tt/embed/amd5YujV8',
+ 'only_matching': True,
+ }]
def _real_extract(self, url):
mobj = re.match(self._VALID_URL, url)