aboutsummaryrefslogtreecommitdiff
path: root/test/test_utils.py
diff options
context:
space:
mode:
authordirkf <fieldhouse@gmx.net>2022-08-14 18:45:45 +0100
committerGitHub <noreply@github.com>2022-08-14 18:45:45 +0100
commitd231b56717c73ee597d2e077d11b69ed48a1b02d (patch)
treed38a1b2f948b150c253ba91cc8568b6225fa29fd /test/test_utils.py
parente6a836d54ca1d3cd02f3ee45ef707a46f23e8291 (diff)
[jsinterp] Overhaul JSInterp to handle new YT players 4c3f79c5, 324f67b9 (#31170)
* back-port from yt-dlp 8f53dc44a0cc1c2d98c35740b9293462c080f5d0, thanks pukkandan * also support void, improve <</>> precedence, improve expressions in comma-list * add more tests
Diffstat (limited to 'test/test_utils.py')
-rw-r--r--test/test_utils.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/test/test_utils.py b/test/test_utils.py
index 259c4763e..f1a748dde 100644
--- a/test/test_utils.py
+++ b/test/test_utils.py
@@ -370,6 +370,9 @@ class TestUtil(unittest.TestCase):
self.assertEqual(unified_timestamp('Sep 11, 2013 | 5:49 AM'), 1378878540)
self.assertEqual(unified_timestamp('December 15, 2017 at 7:49 am'), 1513324140)
self.assertEqual(unified_timestamp('2018-03-14T08:32:43.1493874+00:00'), 1521016363)
+ self.assertEqual(unified_timestamp('December 31 1969 20:00:01 EDT'), 1)
+ self.assertEqual(unified_timestamp('Wednesday 31 December 1969 18:01:26 MDT'), 86)
+ self.assertEqual(unified_timestamp('12/31/1969 20:01:18 EDT', False), 78)
def test_determine_ext(self):
self.assertEqual(determine_ext('http://example.com/foo/bar.mp4/?download'), 'mp4')