Companion

object Companion

Functions

Link copied to clipboard

Creates a ParameterMatcher that matches anything This is the weakest ParameterMatcher.

Link copied to clipboard
fun <T> eq(value: T): ParameterMatcher<T>

Creates a ParameterMatcher that matches only a given value. This is the strongest ParameterMatcher

Link copied to clipboard
fun <T : Any, S : T> isInstance(subclass: KClass<S>): ParameterMatcher<T>

Creates a ParameterMatcher that matches any value that is an instance of a given class This is stronger than notNull but weaker than notEq.

Link copied to clipboard
fun <T> matching(condition: (T) -> Boolean): ParameterMatcher<T>

Creates a ParameterMatcher that matches based on a given condition. This is stronger than notEq but weaker than oneOf.

Link copied to clipboard
fun <T> notEq(value: T): ParameterMatcher<T>

Creates a ParameterMatcher that matches anything but a given value This is stronger than isInstance but weaker than matches.

Link copied to clipboard

Creates a ParameterMatcher that matches only non-null values This is stronger than any but weaker than isInstance.

Link copied to clipboard
fun <T> oneOf(values: List<T>): ParameterMatcher<T>

Creates a ParameterMatcher that matches any value in a given list This is stronger than matches but weaker than eq.