[ruutu] Extend _VALID_URL (closes #24839)
authorSergey M․ <dstftw@gmail.com>
Fri, 11 Dec 2020 22:05:52 +0000 (05:05 +0700)
committerSergey M․ <dstftw@gmail.com>
Fri, 11 Dec 2020 22:10:54 +0000 (05:10 +0700)
youtube_dl/extractor/ruutu.py

index f984040aa07b08f56b1028d0dde1dc3fc78137cb..4dbd144bcfb6f27dae64e5aba3acbbea38dbd659 100644 (file)
@@ -13,7 +13,7 @@ from ..utils import (
 
 
 class RuutuIE(InfoExtractor):
-    _VALID_URL = r'https?://(?:www\.)?(?:ruutu|supla)\.fi/(?:video|supla)/(?P<id>\d+)'
+    _VALID_URL = r'https?://(?:www\.)?(?:ruutu|supla)\.fi/(?:video|supla|audio)/(?P<id>\d+)'
     _TESTS = [
         {
             'url': 'http://www.ruutu.fi/video/2058907',
@@ -71,8 +71,15 @@ class RuutuIE(InfoExtractor):
                 'thumbnail': r're:^https?://.*\.jpg$',
                 'age_limit': 0,
             },
-            'expected_warnings': ['HTTP Error 502: Bad Gateway'],
-        }
+            'expected_warnings': [
+                'HTTP Error 502: Bad Gateway',
+                'Failed to download m3u8 information',
+            ],
+        },
+        {
+            'url': 'http://www.supla.fi/audio/2231370',
+            'only_matching': True,
+        },
     ]
 
     def _real_extract(self, url):