[crunchyroll] Add .fr domain (#4537)
authorSergey M․ <dstftw@gmail.com>
Sun, 21 Dec 2014 18:58:15 +0000 (00:58 +0600)
committerSergey M․ <dstftw@gmail.com>
Sun, 21 Dec 2014 18:58:15 +0000 (00:58 +0600)
youtube_dl/extractor/crunchyroll.py

index 2c7756eb6ae802fa4d4ecd2d93fd8b2e60e51ca6..354046a9e1428bac87f5d9709d16d43308c84555 100644 (file)
@@ -29,8 +29,8 @@ from .common import InfoExtractor
 
 
 class CrunchyrollIE(SubtitlesInfoExtractor):
-    _VALID_URL = r'https?://(?:(?P<prefix>www|m)\.)?(?P<url>crunchyroll\.com/(?:[^/]*/[^/?&]*?|media/\?id=)(?P<video_id>[0-9]+))(?:[/?&]|$)'
-    _TEST = {
+    _VALID_URL = r'https?://(?:(?P<prefix>www|m)\.)?(?P<url>crunchyroll\.(?:com|fr)/(?:[^/]*/[^/?&]*?|media/\?id=)(?P<video_id>[0-9]+))(?:[/?&]|$)'
+    _TESTS = [{
         'url': 'http://www.crunchyroll.com/wanna-be-the-strongest-in-the-world/episode-1-an-idol-wrestler-is-born-645513',
         'info_dict': {
             'id': '645513',
@@ -46,7 +46,10 @@ class CrunchyrollIE(SubtitlesInfoExtractor):
             # rtmp
             'skip_download': True,
         },
-    }
+    }, {
+        'url': 'http://www.crunchyroll.fr/girl-friend-beta/episode-11-goodbye-la-mode-661697',
+        'only_matching': True,
+    }]
 
     _FORMAT_IDS = {
         '360': ('60', '106'),