From f358db9b526834e96ce9b5b429aaeca17d4cf5d9 Mon Sep 17 00:00:00 2001 From: bealler Date: Mon, 15 Feb 2021 15:02:38 -0500 Subject: [PATCH] Check manager state before AP model is tested --- py-scripts/tip-cicd-sanity/Nightly_Sanity.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/py-scripts/tip-cicd-sanity/Nightly_Sanity.py b/py-scripts/tip-cicd-sanity/Nightly_Sanity.py index 094b3883..c24b1dd2 100755 --- a/py-scripts/tip-cicd-sanity/Nightly_Sanity.py +++ b/py-scripts/tip-cicd-sanity/Nightly_Sanity.py @@ -389,13 +389,21 @@ for key in equipment_ids: except: ap_cli_info = "ERROR" print("Cannot Reach AP CLI, will not test this variant") + report_data["pass_percent"][key] = "AP offline" continue fw_model = ap_cli_fw.partition("-")[0] print('Current Active AP FW from CLI:', ap_cli_fw) - ###Find Latest FW for Current AP Model and Get FW ID + if ap_cli_info['state'] != "active": + print('Manager Status not Active. Skipping AP Model!') + report_data["pass_percent"][key] = "AP offline" + continue + else: + print('Manager Status Active. Proceed with tests...') + ###Find Latest FW for Current AP Model and Get FW ID + time.sleep(30) ##Compare Latest and Current AP FW and Upgrade latest_ap_image = ap_latest_dict[fw_model]