Getting total time of a Validation Process

Angel Guillermo Hidalgo, modified 10 Years ago.

Getting total time of a Validation Process

Padawan Posts: 62 Join Date: 12/20/13 Recent Posts

I need to calculate a total time, which is spent executing a group of TestSuite.

The idea is to know how much time is spent executing a Test Plan.

Thanks in advance.

Angel Hidalgo
Torsten Stolpmann, modified 10 Years ago.

RE: Getting total time of a Validation Process (Answer)

Jedi Council Member Posts: 756 Join Date: 2/12/09 Recent Posts
Hi Angel,

you may achieve this by creating a custom report which traverses all the test runs you would like to evaluate and adding up the individual execution times in the contained test results.

The duration (in ms) for each test case result can be determined by the getExecutionTime() method of the KlarosTestCaseResult class, you will have to add up all these values to get your intended result. The KlarosTestCaseResult instances can be found by the getResults() method in the KlarosTestRun class.

If you group the test suites you would like to investigate using nested jobs (one parent job, one sub-job per test suite) you can get to the test runs quite easily using getTestRuns() in the KlarosJob class. You just need to identify the parent job and list the sub jobs via getSubJobs() in the KlarosJob class.

Hope this helps,