From 88b4d023ad208abebc67e2e903d7fa2c938bb4ca Mon Sep 17 00:00:00 2001 From: Mathieu Trudel-Lapierre Date: Thu, 8 Mar 2018 13:30:00 +0100 Subject: [PATCH] Use the CSafeLoader YAML loader to catch issues with complex objects --- tests/test_yaml.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_yaml.py b/tests/test_yaml.py index a8a9a86..ae124c1 100755 --- a/tests/test_yaml.py +++ b/tests/test_yaml.py @@ -90,7 +90,7 @@ class YamlTest(TestBase): # convert excuses to source indexed dict excuses_dict = {} - for s in yaml.load(excuses_yaml)['sources']: + for s in yaml.load(excuses_yaml, Loader=yaml.CSafeLoader)['sources']: excuses_dict[s['source']] = s if 'SHOW_EXCUSES' in os.environ: