aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/gamekings.py
diff options
context:
space:
mode:
authorrobin <rderooij685@gmail.com>2015-02-08 14:23:37 +0100
committerrobin <rderooij685@gmail.com>2015-02-08 14:23:37 +0100
commitba322d82090bd1126774e772b699283121ffa4b8 (patch)
tree274fb690771108240a4ef21a199ae167e2fc3590 /youtube_dl/extractor/gamekings.py
parent2f38289b79ed6c265f2e7cc91e417d0f2178371a (diff)
[Gamekings] Added test and replaced video_url
Quick and dirty fix for the Gamekings extractor. It gives an error about the video_url, but it downloads it now instead of giving a 404 error on newer Gamekings videos
Diffstat (limited to 'youtube_dl/extractor/gamekings.py')
-rw-r--r--youtube_dl/extractor/gamekings.py15
1 files changed, 13 insertions, 2 deletions
diff --git a/youtube_dl/extractor/gamekings.py b/youtube_dl/extractor/gamekings.py
index a5d854ade..aa589390a 100644
--- a/youtube_dl/extractor/gamekings.py
+++ b/youtube_dl/extractor/gamekings.py
@@ -7,7 +7,8 @@ from .common import InfoExtractor
class GamekingsIE(InfoExtractor):
_VALID_URL = r'http://www\.gamekings\.tv/videos/(?P<name>[0-9a-z\-]+)'
- _TEST = {
+ _TESTS = [
+ {
'url': 'http://www.gamekings.tv/videos/phoenix-wright-ace-attorney-dual-destinies-review/',
# MD5 is flaky, seems to change regularly
# 'md5': '2f32b1f7b80fdc5cb616efb4f387f8a3',
@@ -16,8 +17,17 @@ class GamekingsIE(InfoExtractor):
'ext': 'mp4',
'title': 'Phoenix Wright: Ace Attorney \u2013 Dual Destinies Review',
'description': 'md5:36fd701e57e8c15ac8682a2374c99731',
+ }
+ },
+ {
+ 'url': 'http://www.gamekings.tv/videos/the-legend-of-zelda-majoras-mask/',
+ 'info_dict': {
+ 'id': '118933752',
+ 'ext': 'mp4',
+ 'title': 'The Legend of Zelda: Majora’s Mask'
+ }
}
- }
+ ]
def _real_extract(self, url):
@@ -33,6 +43,7 @@ class GamekingsIE(InfoExtractor):
video_url = video_url.replace(video_id, 'large/' + video_id)
if not (self._is_valid_url(video_url, video_id)):
video_url = video_url.replace('large/' + video_id, video_id)
+ video_url = video_url.replace('http://stream.gamekings.tv/', '')
return {
'id': video_id,