From f5225737877a78f63b9a6f1de675c95c650f65d6 Mon Sep 17 00:00:00 2001 From: chris <6024426+iw0nderhow@users.noreply.github.com> Date: Sat, 1 Jan 2022 22:07:00 +0100 Subject: [extractor] Extract chapters from JSON-LD (#2031) Authored by: iw0nderhow, pukkandan --- test/test_InfoExtractor.py | 59 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) (limited to 'test/test_InfoExtractor.py') diff --git a/test/test_InfoExtractor.py b/test/test_InfoExtractor.py index 25bc00e0b..866ded243 100644 --- a/test/test_InfoExtractor.py +++ b/test/test_InfoExtractor.py @@ -208,6 +208,65 @@ class TestInfoExtractor(unittest.TestCase): }, {'expected_type': 'NewsArticle'}, ), + ( + r''' + ''', + { + 'chapters': [ + {"title": "Explosie Turnhout", "start_time": 70, "end_time": 440}, + {"title": "Jaarwisseling", "start_time": 440, "end_time": 1179}, + {"title": "Natuurbranden Colorado", "start_time": 1179, "end_time": 1263}, + {"title": "Klimaatverandering", "start_time": 1263, "end_time": 1367}, + {"title": "Zacht weer", "start_time": 1367, "end_time": 1383}, + {"title": "Financiƫle balans", "start_time": 1383, "end_time": 1484}, + {"title": "Club Brugge", "start_time": 1484, "end_time": 1575}, + {"title": "Mentale gezondheid bij topsporters", "start_time": 1575, "end_time": 1728}, + {"title": "Olympische Winterspelen", "start_time": 1728, "end_time": 1873}, + {"title": "Sober oudjaar in Nederland", "start_time": 1873, "end_time": 2079.23} + ], + 'title': 'Het journaal - Aflevering 365 (Seizoen 2021)' + }, {} + ), ( # test multiple thumbnails in a list r''' -- cgit v1.2.3