# -*- coding: utf-8 -*- import names import time ################################################################################ # This test need to be changed when the Service screen has been implemented # # This is only checking the functionality exists and it's working # ################################################################################ def main(): startApplication("denaliSquish") # Check the Home screen has the settings button on the Main Menu test.compare(str(waitForObjectExists(names.o_mainMenu_settings ).text.text), "Settings" , "SRSUI 028") # Click on Settings button on the Main Menu mouseClick (waitForObjectExists(names.o_mainMenu_settings )) # Upon depress the settings screen shall be visible test.compare(waitForObjectExists(names.o_settingsHome ).visible, True , "SRSUI 029") # Check the shutdown button exists test.compare(waitForObjectExists(names.o_poweroffButton).visible, True) # Click on shutdown button mouseClick (waitForObjectExists(names.o_poweroffButton)) # The PowerOff screen shall have a shutdown button test.compare(waitForObjectExists(names.o_poweroff_shutdown).visible, True) # Click on the PowerOff Dialog's shutdown button mouseClick (waitForObjectExists(names.o_poweroff_shutdown)) # Wait for the animation time.sleep(1) # Going back to the screen which has the PowerOff screen test.compare(waitForObjectExists(names.o_poweroffButton).visible, True) # Click on shutdown button mouseClick (waitForObjectExists(names.o_poweroffButton)) # The PowerOff screen shall have a Cancel button test.compare(waitForObjectExists(names.o_poweroff_cancel).visible, True) # Click on the PowerOff Dialog's Cancel button mouseClick (waitForObjectExists(names.o_poweroff_cancel)) # Wait for the animation time.sleep(1) # Go back to Home Screen mouseClick (waitForObjectExists(names.o_mainMenu_treatment)) test.compare(waitForObjectExists(names.o_treatmentHome).visible, True , "SRSUI 535") print(0)