sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #50641
Re: [Question #678689]: Mojave : SikuliX IDE : Suite Setup works but Suite Teardown fails in this example
Question #678689 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/678689
Status: Open => Answered
RaiMan proposed the following answer:
Again after repairing the script with regard to column structure (more
than 1 space to divide columns), this worked for me:
I did not check Suite Setup/Teardown in the docs, so I simply commented
it out and added the actions to the respective keywords.
runScript("""
robot
*** Variables ***
${TESTAPP} "preview"
${APPTITLE} "preview"
*** Settings ***
Library ./inline/LabQuestViewer
#Suite Setup start my application ${TESTAPP}
#Suite Teardown stop my application ${APPTITLE}
*** Test Cases ***
Test Robot Framework Logging 1
[Setup] Setup Actions
Log Test Logging 1
[Teardown] Teardown Actions
*** Keywords ***
Setup Actions
Log Setup Actions done here
start my application ${TESTAPP}
Teardown Actions
Log Teardown Actions done here
stop my application ${TESTAPP}
""")
class LabQuestViewer(object):
def start_my_application(self, myApp):
someApp = App.open(myApp)
def stop_my_application(self, lqApp):
someApp = switchApp(lqApp)
someApp = App.close(lqApp)
Generally:
when using keywords written in Python, you should first check in a Python script, wether the keywords do what you expect, before using them inline in a RFW script.
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.