DoubleSource
Annotation to indicate that the annotated double parameter should be populated with a random value from the provided values array.
Samples
/**
* This will generate 4 tests with the values 1 - 3, 5
*/
@GeneratedParametersTest
fun testDoubleSource(@DoubleSource(values = [1.0, 2.0, 3.0, 5.0]) value: Int) {
assertThat(value).isIn(1.0, 2.0, 3.0, 5.0)
}Content copied to clipboard