Method Tools.Shoot.run_sub()
- Method
run_sub
voidrun_sub(Testtest,intmaximum_seconds,__deprecated__(float)|voidoverhead)- Description
Run a single benchmark test in the current process and return the result as JSON on stdout.
- Parameter
test Benchmark to run.
- Parameter
maximum_seconds Number of seconds to run the test before terminating it.
- Parameter
overhead Ignored, obsolete.
- Returns
Writes a JSON-encoded mapping with the following fields on success:
"time":floatActual number of seconds that the test ran.
"loops":intNumber of times that the test ran.
"n":intNumber of sub tests that were run.
"readable":stringDescription of the test result.
"n_over_time":intNumber of sub tests per second.
On benchmark failure a JSON-encoded mapping with the single entry
"readable"set to"FAIL"is written to stdout.- Note
This is the funcction that is called in a sub-process by run().
- See also