1
0
Fork 0
mirror of https://github.com/ytdl-org/youtube-dl.git synced 2024-12-01 06:27:44 +00:00

[uplynk,viceland] update tests and change uplynk extractors names

This commit is contained in:
Remita Amine 2016-08-14 22:45:43 +01:00
parent 525e0316c0
commit 24eb13b1c6
2 changed files with 4 additions and 1 deletions

View file

@ -11,6 +11,7 @@ from ..utils import (
class UplynkIE(InfoExtractor): class UplynkIE(InfoExtractor):
IE_NAME = 'uplynk'
_VALID_URL = r'https?://.*?\.uplynk\.com/(?P<path>ext/[0-9a-f]{32}/(?P<external_id>[^/?&]+)|(?P<id>[0-9a-f]{32}))\.(?:m3u8|json)(?:.*?\bpbs=(?P<session_id>[^&]+))?' _VALID_URL = r'https?://.*?\.uplynk\.com/(?P<path>ext/[0-9a-f]{32}/(?P<external_id>[^/?&]+)|(?P<id>[0-9a-f]{32}))\.(?:m3u8|json)(?:.*?\bpbs=(?P<session_id>[^&]+))?'
_TEST = { _TEST = {
'url': 'http://content.uplynk.com/e89eaf2ce9054aa89d92ddb2d817a52e.m3u8', 'url': 'http://content.uplynk.com/e89eaf2ce9054aa89d92ddb2d817a52e.m3u8',
@ -54,7 +55,9 @@ class UplynkIE(InfoExtractor):
class UplynkPreplayIE(UplynkIE): class UplynkPreplayIE(UplynkIE):
IE_NAME = 'uplynk:preplay'
_VALID_URL = r'https?://.*?\.uplynk\.com/preplay2?/(?P<path>ext/[0-9a-f]{32}/(?P<external_id>[^/?&]+)|(?P<id>[0-9a-f]{32}))\.json' _VALID_URL = r'https?://.*?\.uplynk\.com/preplay2?/(?P<path>ext/[0-9a-f]{32}/(?P<external_id>[^/?&]+)|(?P<id>[0-9a-f]{32}))\.json'
_TEST = None
def _real_extract(self, url): def _real_extract(self, url):
path, external_id, video_id = re.match(self._VALID_URL, url).groups() path, external_id, video_id = re.match(self._VALID_URL, url).groups()

View file

@ -36,7 +36,7 @@ class VicelandIE(AdobePass):
# m3u8 download # m3u8 download
'skip_download': True, 'skip_download': True,
}, },
'add_ie': ['UplynkPreplay', 'Uplynk'], 'add_ie': ['UplynkPreplay'],
} }
def _real_extract(self, url): def _real_extract(self, url):