You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

78 lines
2.8 KiB

11 years ago
  1. # encoding: utf-8
  2. from __future__ import unicode_literals
  3. from .mtv import MTVServicesInfoExtractor
  4. class SouthParkIE(MTVServicesInfoExtractor):
  5. IE_NAME = 'southpark.cc.com'
  6. _VALID_URL = r'https?://(?:www\.)?(?P<url>southpark\.cc\.com/(?:clips|full-episodes)/(?P<id>.+?)(\?|#|$))'
  7. _FEED_URL = 'http://www.southparkstudios.com/feeds/video-player/mrss'
  8. _TESTS = [{
  9. 'url': 'http://southpark.cc.com/clips/104437/bat-daded#tab=featured',
  10. 'info_dict': {
  11. 'id': 'a7bff6c2-ed00-11e0-aca6-0026b9414f30',
  12. 'ext': 'mp4',
  13. 'title': 'South Park|Bat Daded',
  14. 'description': 'Randy disqualifies South Park by getting into a fight with Bat Dad.',
  15. },
  16. }]
  17. class SouthParkEsIE(SouthParkIE):
  18. IE_NAME = 'southpark.cc.com:español'
  19. _VALID_URL = r'https?://(?:www\.)?(?P<url>southpark\.cc\.com/episodios-en-espanol/(?P<id>.+?)(\?|#|$))'
  20. _LANG = 'es'
  21. _TESTS = [{
  22. 'url': 'http://southpark.cc.com/episodios-en-espanol/s01e01-cartman-consigue-una-sonda-anal#source=351c1323-0b96-402d-a8b9-40d01b2e9bde&position=1&sort=!airdate',
  23. 'playlist_count': 4,
  24. }]
  25. class SouthParkDeIE(SouthParkIE):
  26. IE_NAME = 'southpark.de'
  27. _VALID_URL = r'https?://(?:www\.)?(?P<url>southpark\.de/(?:clips|alle-episoden)/(?P<id>.+?)(\?|#|$))'
  28. _FEED_URL = 'http://www.southpark.de/feeds/video-player/mrss/'
  29. _TESTS = [{
  30. 'url': 'http://www.southpark.de/clips/uygssh/the-government-wont-respect-my-privacy#tab=featured',
  31. 'info_dict': {
  32. 'id': '85487c96-b3b9-4e39-9127-ad88583d9bf2',
  33. 'ext': 'mp4',
  34. 'title': 'The Government Won\'t Respect My Privacy',
  35. 'description': 'Cartman explains the benefits of "Shitter" to Stan, Kyle and Craig.',
  36. },
  37. }, {
  38. # non-ASCII characters in initial URL
  39. 'url': 'http://www.southpark.de/alle-episoden/s18e09-hashtag-aufwärmen',
  40. 'playlist_count': 4,
  41. }, {
  42. # non-ASCII characters in redirect URL
  43. 'url': 'http://www.southpark.de/alle-episoden/s18e09',
  44. 'playlist_count': 4,
  45. }]
  46. class SouthParkNlIE(SouthParkIE):
  47. IE_NAME = 'southpark.nl'
  48. _VALID_URL = r'https?://(?:www\.)?(?P<url>southpark\.nl/(?:clips|full-episodes)/(?P<id>.+?)(\?|#|$))'
  49. _FEED_URL = 'http://www.southpark.nl/feeds/video-player/mrss/'
  50. _TESTS = [{
  51. 'url': 'http://www.southpark.nl/full-episodes/s18e06-freemium-isnt-free',
  52. 'playlist_count': 4,
  53. }]
  54. class SouthParkDkIE(SouthParkIE):
  55. IE_NAME = 'southparkstudios.dk'
  56. _VALID_URL = r'https?://(?:www\.)?(?P<url>southparkstudios\.dk/(?:clips|full-episodes)/(?P<id>.+?)(\?|#|$))'
  57. _FEED_URL = 'http://www.southparkstudios.dk/feeds/video-player/mrss/'
  58. _TESTS = [{
  59. 'url': 'http://www.southparkstudios.dk/full-episodes/s18e07-grounded-vindaloop',
  60. 'playlist_count': 4,
  61. }]