From 320775e606fd6ec7839e89f8a556811a40a727a0 Mon Sep 17 00:00:00 2001 From: John Hawkinson Date: Sat, 8 Apr 2017 00:21:11 -0400 Subject: [PATCH 1/2] [test_download] Improve diagnostic on wrong 'id' --- test/test_download.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/test_download.py b/test/test_download.py index 01a8bcb89..bd9dd86e8 100644 --- a/test/test_download.py +++ b/test/test_download.py @@ -11,6 +11,7 @@ sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) from test.helper import ( assertGreaterEqual, expect_warnings, + expect_value, get_params, gettestcases, expect_info_dict, @@ -200,6 +201,7 @@ def generator(test_case, tname): test_case['playlist_duration_sum'], got_duration) for tc in test_cases: + expect_value(self, res_dict['id'], tc['info_dict']['id'], 'id') tc_filename = get_tc_filename(tc) if not test_case.get('params', {}).get('skip_download', False): self.assertTrue(os.path.exists(tc_filename), msg='Missing file ' + tc_filename) From 3058b4014600d385f208fd90d3675275bea1d5c7 Mon Sep 17 00:00:00 2001 From: John Hawkinson Date: Sat, 8 Apr 2017 00:27:52 -0400 Subject: [PATCH 2/2] [test_download] typo in comment --- test/test_download.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/test_download.py b/test/test_download.py index bd9dd86e8..61015562d 100644 --- a/test/test_download.py +++ b/test/test_download.py @@ -152,7 +152,7 @@ def generator(test_case, tname): try_num = 1 while True: try: - # We're not using .download here sine that is just a shim + # We're not using .download here since that is just a shim # for outside error handling, and returns the exit code # instead of the result dict. res_dict = ydl.extract_info(