Forum Discussion
SKoneru
13 years agoContributor
Attached is the custom JunitReportCollector java file. I changed the extension to .rtf as the forum didn't allow me to attach a .java extension file.
What I achieved:-
1- For each row in the data source, I was able to generate a new testcase entry.
Note:- There can be nested datasource within a testcase, I identified the actual outer data source loop by appending the test step with name "newtc"
2- In case of failed testcase, I was able to dump all the test steps
3- Numbered each test step within a test case.
4- Attached the generated request/response/status file for each test step.
Concerns:-
A- Was not able to display test steps when the test case is "SUCCESS". For this I think the framework should provide an additional API in JunitReport class that takes message.
Currently we have only report.addTestCase(String name,long time); but there should be an API that takes message and displays, something like report.addTestCase(String name, long time, String message).
Should I log an enhancement request in the forum?
B- Wondering if #1 is the right way to display a new test case entry for each row in data source. Is there a better approach?
C- Any other suggestions will be great
What I achieved:-
1- For each row in the data source, I was able to generate a new testcase entry.
Note:- There can be nested datasource within a testcase, I identified the actual outer data source loop by appending the test step with name "newtc"
2- In case of failed testcase, I was able to dump all the test steps
3- Numbered each test step within a test case.
4- Attached the generated request/response/status file for each test step.
Concerns:-
A- Was not able to display test steps when the test case is "SUCCESS". For this I think the framework should provide an additional API in JunitReport class that takes message.
Currently we have only report.addTestCase(String name,long time); but there should be an API that takes message and displays, something like report.addTestCase(String name, long time, String message).
Should I log an enhancement request in the forum?
B- Wondering if #1 is the right way to display a new test case entry for each row in data source. Is there a better approach?
C- Any other suggestions will be great