Forum Discussion
Congratulation tristaanogre for your 2000th Post , ya sure will try it and get back to you.
Hey, JackSparrow,
Something I noticed in looking at the Log.SaveResultsAs documentation that I missed before is that there is a "scope" option. By default, when you do "Log.SaveResultsAs", it will dump the ENTIRE test log out. However, if you set that parameter to "lesCurrentTestItem" or "2", it will export the log for ONLY the current test item being executed.
This MIGHT solve your problem and preclude the need for you to write special code for creating your own HTML log.
So, to recap, what you would do is something like this:
def Test1(): # Do something # ... Log.SaveResultsAs("C:\\Work\\Log\\", lsHTML, false, lesCurrentTestItem) # Files are created in the Log folder
Where that code would be the last line of code executed in your TestItem OR could be called as part of the OnStopTest event handler code that would fire after every test item is completed.