When running a timed run, the time is stored on the TestCase as RUN_TIME. This
is the planned run-time. As the runtime is checked after each run, the actual
runtime is guaranteed to be longer than this.
JapexDriverBase.run() calculates the actual run duration and stores that as
ACTUAL_RUN_TIME on the TestCaseImpl:
The TPS is later computed by this code in Engine.computeResultValue(TestCase tc,
int nOfThreads, int nOfCpus):
tps = tc.getLongParam(Constants.RUN_ITERATIONS_SUM) /
(Util.parseDuration(tc.getParam(Constants.RUN_TIME)) / 1000.0);
Where RUN_ITERATIONS_SUM is the number of times that the test was run. This is
incorrect. If an iteration takes 100s, but the RUN_TIME was 10s, the TPS number
indicates that the run performed one run per second, rather than the actual 0.1 TPS.
The correct code should read:
tps = tc.getLongParam(Constants.RUN_ITERATIONS_SUM)