Generate a Report after running a Testsuite
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-09-2019
05:17 AM
08-09-2019
05:17 AM
Generate a Report after running a Testsuite
I have set up a Testsuite with 17 testcases. Rather than going into each case to see the output, i would like to print the Output (responses) into 1 file.
Is there a way to do this, and if so, how? Im using SoapUI version 5.4.0 Free Version
Thanks in advance
Solved! Go to Solution.
3 REPLIES 3
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-21-2019
03:23 AM
08-21-2019
03:23 AM
Hi @Mehman87 ,
Yes it can be achieved by writting custom groovy code. Let me know if you need help on this.
Click "Accept as Solution" if my answer has helped,
Remember to give "Kudos" 🙂 ↓↓↓↓↓
Thanks and Regards,
Himanshu Tayal
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-22-2019
02:39 AM
08-22-2019
02:39 AM
Thanks for your help on this @HimanshuTayal
Are you able to send me an example of the code required please?
Thanks
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-22-2019
03:00 AM
08-22-2019
03:00 AM
Start with something basic like this in the TestSuite Teardown Script. Expand it as required:
import com.eviware.soapui.impl.support.http.HttpRequestTestStep File out = new File("/temp/blah.txt") testSuite.testCaseList.each { it.testStepList.findAll { it instanceof HttpRequestTestStep }.each { out << "${it.testCase.name} -- ${it.name}" + "\n" out << it.httpRequest.requestContent + "\n\n" out << it.httpRequest.response.contentAsString + "\n\n" } }
