Forum Discussion
Sorry, did not get what you mean by - "get properties of a run test case".
Could you please show a screen shot along with the script you have for the review?
How many such cases there for you to be clean up?
Where the current script placed? Is it in a common place or in a specific test case ?
As you know there is no out-of-the-box functionality, need to understand the use case. So answering above info will help.
Hi,
ReadyApi provides the concepts of Setup and Tear down scripts. The Setup script runs before a certain phase (either Project, Test Suite or Test Case) while the Tearn down script runs after a certain phase.
That being said, if you want to run a script after the project is run, you can click on the project in the Navigator, click on Tear down script and add your code there.
Later edit: it was only after I posted that I saw you wanted this to happen when closing a project and not after the project was ran. I don't really have a solution for this.
- asseldonk016 years agoContributor
Hi Rao and Lucian,
Thanks for your remarks. First i learned that describing something in a post is not that easy. You believe that it is clear but that is certainly not always the case.
I was looking for a way to call a groovy script when closing a project. I will now have a more closer look at teardown scripts and maybe again events.
Thanks!
- nmrao6 years agoChampion Level 3More information will reduce the time for the better answers, and number of iterations as well.
When there is script already, why let the others to imagine ?
Depends on the context, the same script may work from certain place and the same may not work from other place.
For example, if script is provided at Script Assertion level, many not work in a groovy script test step. A script of groovy script test step is placed in test suite tear down, may or many not work depending the context variables being used.
That's the reason why asking for the information.
And there is no use of providing some random info to try without full knowledge of understanding of the problem. - nmrao6 years agoChampion Level 3People don't have answers ready, always. Have to understand the problem, spending their valuable time to find out solutions, that helps both seeker and those reply to learn new thins form others problems.
- nmrao6 years agoChampion Level 3One more thing is if the problem is one for one test case, then it would be simple to execute the script. However, the same may not helpful / feasible if it has to done for more number of cases. That is what all makes changes if there is good context to the problem.