atrium-domain-builders-jvm / ch.tutteli.atrium.domain.builders.creating / OptionalAssertionsBuilder

OptionalAssertionsBuilder

object OptionalAssertionsBuilder (source)

Delegates inter alia to the implementation of OptionalAssertions. In detail, it implements OptionalAssertions by delegating to optionalAssertions which in turn delegates to the implementation via loadSingleService.

Functions

isEmpty

fun <T : Optional<*>> isEmpty(expect: <ERROR CLASS><T>): <ERROR CLASS>

isPresent

fun <E, T : Optional<E>> isPresent(expect: <ERROR CLASS><T>): <ERROR CLASS><T, E>

Extension Functions

asExpect

fun <T, A> A.asExpect(): <ERROR CLASS><T>
fun <T : Any, A> A.asExpect(assertionCreator: <ERROR CLASS><T>.() -> Unit): A

Turns Assert or AssertionPlantNullable into an Expect so that you can use new functionality which is not available on Assert/AssertionPlantNullable.