From: Hanoh Haim Date: Sun, 15 Jan 2017 17:48:36 +0000 (+0200) Subject: hotfix for get model - does not work on regression X-Git-Url: https://gerrit.fd.io/r/gitweb?a=commitdiff_plain;h=120746eda312b1dab0460b15c113261bcb34690f;p=trex.git hotfix for get model - does not work on regression Signed-off-by: Hanoh Haim --- diff --git a/scripts/automation/regression/stateful_tests/trex_general_test.py b/scripts/automation/regression/stateful_tests/trex_general_test.py index 24c38783..64f27141 100755 --- a/scripts/automation/regression/stateful_tests/trex_general_test.py +++ b/scripts/automation/regression/stateful_tests/trex_general_test.py @@ -97,9 +97,11 @@ class CTRexGeneral_Test(unittest.TestCase): CTRexScenario.router.load_platform_data_from_file(device_cfg) CTRexScenario.router.launch_connection(device_cfg) if CTRexScenario.router_cfg['forceImageReload']: - running_image = CTRexScenario.router.get_running_image_details()['image'] - setup['dut'] =CTRexScenario.router.get_running_image_details()['model'] + image_d=CTRexScenario.router.get_running_image_details(); + running_image = image_d['image'] + setup['dut'] =image_d.get('model','router'); print('Current router image: %s' % running_image) + print('Current router model : %s' % setup['dut']) needed_image = device_cfg.get_image_name() if not CTRexScenario.router.is_image_matches(needed_image): print('Setting router image: %s' % needed_image)