Walking through TestComplete logs – Part 2
Hi All,
Let me continue with my next post in “Walking through TestComplete logs”
Previous : http://automate101.blogspot.com/2010/06/walking-through-testcomplete-logs.html
Q2:How was the log useful?
The answer can be found throughout this series of post 🙂
TestComplete has log panels which can be customized (Added/Delete/Align). The log panels are very informative when you want to investigate the execution.
The panels in Log explorer are
- LogItems (Has TestComplete items like Project Suite,Project,Test Items…)
- Information (Has time and file information for the current log)
- Log (Has detailed information about the selected item from LogItems)
- Remarks (additional information for the selected item in log)
- Also has – Call Stack, Messages and Extended Messages – I am yet to explore/use this features
According the my understanding a log should convey all the information a user needs. Yes either by default or option to add details in to it.
By default TestComplete reports an Event, Error, Success, Message, Warning and Picture.
In addition to it we can add our own logs using specific functions supplied by “Log” object.
I cannot exactly classify the list of items should and shouldn’t present in the log! It is purely based on the business requirement.
But importantly TestComplete allows to add our logs in to its TestLog during the script execution and even we can block ( Using functions – Log.LockEvents & Log.UnlockEvents ) the default logs.
Also the log should post respective error/warning messages when the object required is changed/not available/disabled/out of window boundary etc.,
Q5: Is the generated Log can be saved for future reference? If so how?
TestComplete allow us to save/export log both at test run time and completion time.
During Run Time:
We can save the logs generated at run time (Upto that time) in to (.XML),(.HTML),(.MHTML) formats.
After run time:
The logs in TestComplete can be exported for reference as (.mhtml), unpacked storage etc.
Also the results can be viewed in IE (only) from the TestComplete Logs. (Since FireFox and Chrome doesn’t support .mhtml files)
- Create an issue based on failure (Issue tracking must be enabled)
- Send the results through email (As .mhtml attachment Using BuiltIn.SendMail method)