Commit 7f9c4f0345815bebf39c752c3a824451bfd03bcd

Authored by Christian Herdtweck
1 parent 8f68844b

unittests: fix error introduced when changing OutputCapture

Showing 1 changed file with 1 additions and 1 deletions
tests/json/test_output.py
@@ -51,7 +51,7 @@ class TestValidJson(unittest.TestCase): @@ -51,7 +51,7 @@ class TestValidJson(unittest.TestCase):
51 if print_output: 51 if print_output:
52 print(capturer.get_data()) 52 print(capturer.get_data())
53 try: 53 try:
54 - json_data = json.load(capturer.get_data()) 54 + json_data = json.loads(capturer.get_data())
55 except ValueError: 55 except ValueError:
56 self.fail('Invalid json:\n' + capturer.get_data()) 56 self.fail('Invalid json:\n' + capturer.get_data())
57 self.assertNotEqual(len(json_data), 0, msg='Output was empty') 57 self.assertNotEqual(len(json_data), 0, msg='Output was empty')