aboutsummaryrefslogtreecommitdiffstats
path: root/test/test_utils.py
diff options
context:
space:
mode:
authorDamiano Amatruda <damiano.amatruda@outlook.com>2021-10-22 02:04:00 +0200
committerGitHub <noreply@github.com>2021-10-22 05:34:00 +0530
commit17ec8bcfa90b80913072fdcb0cafc09c1ad79849 (patch)
tree9fd20e09bbe43c0c4f74fb67c07b0ce8020938ed /test/test_utils.py
parent0f6e60bb5722f03c6b64712f70aaf9b0b6915795 (diff)
downloadhypervideo-pre-17ec8bcfa90b80913072fdcb0cafc09c1ad79849.tar.lz
hypervideo-pre-17ec8bcfa90b80913072fdcb0cafc09c1ad79849.tar.xz
hypervideo-pre-17ec8bcfa90b80913072fdcb0cafc09c1ad79849.zip
[microsoftstream] Add extractor (#1201)
Based on: https://github.com/ytdl-org/youtube-dl/pull/24649 Fixes: https://github.com/ytdl-org/youtube-dl/issues/24440 Authored by: damianoamatruda, nixklai
Diffstat (limited to 'test/test_utils.py')
-rw-r--r--test/test_utils.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/test/test_utils.py b/test/test_utils.py
index d84c3d3ee..810ed3de4 100644
--- a/test/test_utils.py
+++ b/test/test_utils.py
@@ -1163,12 +1163,15 @@ class TestUtil(unittest.TestCase):
def test_parse_resolution(self):
self.assertEqual(parse_resolution(None), {})
self.assertEqual(parse_resolution(''), {})
- self.assertEqual(parse_resolution('1920x1080'), {'width': 1920, 'height': 1080})
- self.assertEqual(parse_resolution('1920×1080'), {'width': 1920, 'height': 1080})
+ self.assertEqual(parse_resolution(' 1920x1080'), {'width': 1920, 'height': 1080})
+ self.assertEqual(parse_resolution('1920×1080 '), {'width': 1920, 'height': 1080})
self.assertEqual(parse_resolution('1920 x 1080'), {'width': 1920, 'height': 1080})
self.assertEqual(parse_resolution('720p'), {'height': 720})
self.assertEqual(parse_resolution('4k'), {'height': 2160})
self.assertEqual(parse_resolution('8K'), {'height': 4320})
+ self.assertEqual(parse_resolution('pre_1920x1080_post'), {'width': 1920, 'height': 1080})
+ self.assertEqual(parse_resolution('ep1x2'), {})
+ self.assertEqual(parse_resolution('1920, 1080'), {'width': 1920, 'height': 1080})
def test_parse_bitrate(self):
self.assertEqual(parse_bitrate(None), None)