in apps/cloudwatch-dashboard/synthetics/dashboard-snapshot.py [0:0]
def adjust_dashboard_ui():
logger.info("### Close the left menu-bar and switch to full screen")
try:
browser.find_element_by_class_name("awsui-app-layout__close-button").click()
except Exception as e:
logger.info("!!! Left menu bar close button not found")
logger.info(e)
try:
# browser.find_element_by_class_name("awsui-flash-action-button").click()
browser.find_element_by_xpath("//*[text()='Execute them all']").click()
except Exception as e:
logger.info("!!! Allow lambda executions button not found")
logger.info(e)
try:
browser.find_element_by_class_name("fullscreen-button").click()
except Exception as e:
logger.info("!!! Full screen button not found")
logger.info(e)
#browser.find_element_by_xpath('//awsui-button[@data-test-id="refresh-dashboard-button"]').click()
dashboard_type = os.environ['DASHBOARD_TYPE']
if dashboard_type == 'ModelEvaluation':
time.sleep(90)
else:
time.sleep(30)