Take Screenshot for pass case also
Hi RaiMan,
I am using Sikuli r930 version on Windows 7 machine.
I am using sikuli for automation.Its helping a lot in our work.
I want to achieve:
I execute the python scripts from sikuli on a device ( windows mobile) and using HTMLTestRunner also.
HTMLTestRunner takes screenshot for failure case and redirects all print statements to HTML report.
I redirected to stdout also for my purpose.
I want to get the screenshots for each step, whether it is pass/fail/error to stdout as well as in report also.
For Example:
try:
click(
print "start found"
assert True
except:
print "Start NOT found"
assert False
try:
click(
print "menu found"
assert True
except:
print "menu NOT found"
assert False
In this example , I want screenshot for each step ( pass/fail/error) in stdout and in report also,
like ,
pt1.1 : start found
menu found
because I want to track the device status after each step.
I am running sikuli from eclipse.So, In eclipse stdout part also I want the screenshots after each step.
I tried modifying HTMLTestRunner.py , but no success.
One doubt is that what happens exactly when execution went to 'assert False' statement?
which function will it call in HTMLTestRunner?
Once one 'assert False' statement occured means , will the script exits or will it proceed to next statemet?
How many failure images can be taken?
Please suggest how to proceed for this , its helps a lot.
Thanks in advance.
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- SikuliX Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Lakshmi for more information if necessary.