Forum Discussion
- StevenC10 years agoContributor
A testcase...
def postProc = testRunner.testCase.testSuite.project.testSuites[suiteName].testCases["postProcessingScripts"]
- StevenC10 years agoContributor
To give some background.
This is a groovy script that controls a load test. You define a run duration (in either total seconds or an end time) and a number of test runs and the script will run through the number of defined test runs, then stop and restart the test. After the test duration has elapsed it executes some post processing scripts, in this particular case there is just 1 to be executed and all it does is query the results from out of the database and writes them to a spreadsheet but in other cases there could be other post processing (such as downloading log files from the tomcat servers and parsing them for information) .
The reason why I have it break up the test runs into defined chunks is so that the results of a 4 hour test with more than 200,000 iterations of the test can be easier processed and represented into graphical format in excel (and the 64,000 row limit in excel is an issue too) .What this is trying to do is to iterate over the test runs and run the getStats script for each of them, the problem is it looks like the values of the properties of that testcase get loaded into the context and never updated even though the script is updating them.
- StevenC10 years agoContributor
I just verified the same issue occurs in both ReadyAPI 1.4.1 and 1.5
- jsreesoap10 years agoContributor
I had similar issue calling properties if other project. When I executed my script it did not pick up the lates values instead it was having previous run values. Support suggested to add project.save() in teardown script tab of the target project. Suppose I am calling properties of project A from project B, have project.save() in project A. I think the teardown or teardown script tab is in project properties. I use Ready Api.