From 6ed986581219c341d8c200f98f3201ec492047dc Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Sat, 30 Sep 2023 12:19:16 +0200 Subject: [PATCH] Use items() to iterate over a dictionary --- tests/test_philips_orientation_dcm_spar_new.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_philips_orientation_dcm_spar_new.py b/tests/test_philips_orientation_dcm_spar_new.py index e18c5c1..bf7c888 100644 --- a/tests/test_philips_orientation_dcm_spar_new.py +++ b/tests/test_philips_orientation_dcm_spar_new.py @@ -181,10 +181,10 @@ def ss_call(x, name): sdat, spar] ) - for key in data: - dcm_call(data[key]['dcm_enhanced'], f'dcm_e_{key}') - dcm_call(data[key]['dcm_classic'], f'dcm_c_{key}') - ss_call(data[key]['spar'], f'spar_{key}') + for key, value in data.items(): + dcm_call(value['dcm_enhanced'], f'dcm_e_{key}') + dcm_call(value['dcm_classic'], f'dcm_c_{key}') + ss_call(value['spar'], f'spar_{key}') all_cases = [] for case in data: