How to uniquely identify TestComplete Testcase operation output in multiple XML logs.
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to uniquely identify TestComplete Testcase operation output in multiple XML logs.
I have a requirement to uniquely identify testcase messages in TestComplete XML log output ( XML Log, generated by TC in the end of Test Suite execution). I will parse these log files and generate a report from it.
In XML Log each element (project suite, project, testcase) has options to identify any of this element uniquely (using monikers and persistent keys), in different XML logs generated by executing Test Suite multiple times.
I do not see a concrete option to identify a Test Case log message in multiple executions. Is there an option to achieve this?
Scenario-
- A) I have a testcase with two operations. In Project suite XML log, I see xml nodes as message 0, message 1 for both operations (I wish TC would have unique identifiers (Monikers and persistent keys) for each message).
- B) If I modify testcase by adding another operation in between operation 0 and 1, upon execution output XML log will show three messages message 0, message 1 and message 2.
By looking at message 1 in A and B execution outcomes, how to find out if “message 1” is same if both runs or not?
Solved! Go to Solution.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm sorry, but I don't understand what you're trying to investigate.
Can you write more details?
Are You creating Your own .xml or You mean the main TestComplete at the end?
Are You parsing somehow the 'App\Log\*' files?
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The "messages" you see are the event logging of the actions being performed. Basically, each step that you do in the test potentially could write a record to the log. If you don't deliberately make effort to write your own log records, organize your tests, etc., then that's all you're going to get in the log... a massive, long list of events. It's a log, not a report.
Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----
Why automate? I do automated testing because there's only so much a human being can do and remain healthy. Sleep is a requirement. So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.
Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am trying to parse XML log files, generate by TC after TestSuite execution.
I can locate any project suite, project and test case by using their persistent key among multiple outputs, how can I find any testcase message among multiple executions? Message ID is just a node locater but it doesn`t necessarily tells if it’s the same. See updated question for details.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I don't know for certain... but I think the message IDs are uniquely generated each run. So you're not going to be able to use a key or ID to tell the difference. You're going to have to go by type of message (event, error, warning, message, checkpoint, etc.) and the actual content of the message.
Question:
Why are you attempting to parse out the XML of the TC log file? What's you're ultimate end goal?
Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----
Why automate? I do automated testing because there's only so much a human being can do and remain healthy. Sleep is a requirement. So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.
Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I agree Message IDs are unique for the run, but it is not helpful for me. I want some property associated with each message which remains unchanged during multiple runs.
I want to generate report out of it, mentioned in updated question.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The "messages" you see are the event logging of the actions being performed. Basically, each step that you do in the test potentially could write a record to the log. If you don't deliberately make effort to write your own log records, organize your tests, etc., then that's all you're going to get in the log... a massive, long list of events. It's a log, not a report.
Is it possible in TC to have own defined structure for XML log? Can you please elaborate "Own log records"?
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
No, TC log structure (the XML) is part of TC. You can't modifiy it.
As for "own log records"... these are any records created using the "Log" operation in keyword tests. If you're not explicitly logging, then it's all the automatic stuff created by TC.
Robert Martin
[Hall of Fame]
Please consider giving a Kudo if I write good stuff
----
Why automate? I do automated testing because there's only so much a human being can do and remain healthy. Sleep is a requirement. So, while people sleep, automation that I create does what I've described above in order to make sure that nothing gets past the final defense of the testing group.
I love good food, good books, good friends, and good fun.
Mysterious Gremlin Master
Vegas Thrill Rider
Extensions available
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Does it help somehow?
/Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you everyone!
@TCU100 , were you able to solve this with all the advice from the Community?
Sonya Mihaljova
Community and Education Specialist
