- Mastering High Performance with Kotlin
- Igor Kucherenko
- 82字
- 2021-06-25 20:55:25
Levels of fixture methods
To control when fixture methods should be run, you can use at least three available options:
- Trial: Specifies that a method should be invoked before or after the entire benchmark run
- Iteration: Specifies that a method should be invoked before or after the benchmark iteration
- Invocation: Specifies that a method should be invoked before or after the benchmark method invocation
You can pass one of these objects as a parameter to the @Setup or @TearDown annotations.