Package-level declarations

Types

Link copied to clipboard
@SourceProvider(value = InstantRangeSourceDataProvider::class)
annotation class InstantRangeSource(val min: String, val max: String, val increment: String = "PT1h", val ascending: Boolean = true)

Used to provide a range of instants to a test. The range is inclusive of the min and max values.

Link copied to clipboard
@SourceProvider(value = InstantValueSourceDataProvider::class)
annotation class InstantSource(val values: Array<String>)

Annotation to be utilized on a parameter of type Instant in a parameterized test. The annotated parameter;s value will be populated with a randomized value derived from the provided values array.

Link copied to clipboard
@SourceProvider(value = LocalDateRangeDataProvider::class)
annotation class LocalDateRangeSource(val min: String, val max: String, val increment: String = "P1d", val ascending: Boolean = true, val dateFormat: String = "yyyy-MM-dd")

Annotation to indicate that the annotated LocalDate parameter should be populated with a LocalDate range from min to max with an increment step in the ascending direction. The default increment is 1 day. The default ascending is true.

Link copied to clipboard
@SourceProvider(value = LocalDateValueSourceDataProvider::class)
annotation class LocalDateSource(val values: Array<String>, val dateFormat: String = "yyyy-MM-dd")

Annotation to indicate that the annotated LocalDate parameter should be populated with a random value from the provided values array.

Link copied to clipboard
@SourceProvider(value = LocalDateTimeRangeDataProvider::class)
annotation class LocalDateTimeRangeSource(val min: String, val max: String, val increment: String = "PT1h", val ascending: Boolean = true, val dateTimeFormat: String = "yyyy-MM-dd HH:mm")

Annotation to indicate that the annotated LocalDateTime parameter should be populated with a LocalDateTime range from min to max with an increment step in the ascending direction. The default increment is 1 hour. The default ascending is true.

Link copied to clipboard
@SourceProvider(value = LocalDateTimeValueSourceDataProvider::class)
annotation class LocalDateTimeSource(val values: Array<String>, val dateTimeFormat: String = "yyyy-MM-dd HH:mm")

Annotation to indicate that the annotated LocalDateTime parameter should be populated with a random value from the provided values array.

Link copied to clipboard
@SourceProvider(value = LocalDateTimeRangeDataProvider::class)
annotation class LocalTimeRangeSource(val min: String, val max: String, val increment: String = "PT1h", val ascending: Boolean = true, val timeFormat: String = "HH:mm")

Annotation to mark that the given LocalTime parameter should be populated with a LocalTime range starting from the minimum value min to the maximum value max with an increment in the direction specified by ascending. The default increment is 1 hour and the default ascending order is true.

Link copied to clipboard
@SourceProvider(value = LocalDateTimeValueSourceDataProvider::class)
annotation class LocalTimeSource(val values: Array<String>, val timeFormat: String = "HH:mm")

Annotation to be utilized on a parameter of type LocalTime in a parametrized test. The annotated parameter's value will be populated with a randomized value derived from the provided values array.

Link copied to clipboard
@SourceProvider(value = RandomInstanceSourceDataProvider::class)
annotation class RandomInstantSource(val min: String = "", val max: String = "", val useOffset: Boolean = false, val size: Int, val truncateTo: TruncateChronoUnit = TruncateChronoUnit.MINUTES)

This annotation is used to generate random java.time.Instants. The min and max values are used to determine the range of values to generate. If useOffset is true, the min and max values are treated as offsets from the current time. Otherwise, the min and max values are treated as java.time.Instants. The size parameter determines the number of random values to generate. The truncateTo parameter determines the truncation unit that the starting instant will be truncated to.