doc / ch.tutteli.atrium.api.cc.en_GB / value

value

fun <T : CharSequence> CheckerOption<T, NoOpSearchBehaviour>.value(expected: Any): AssertionPlant<T> (source)

Finishes the specification of the sophisticated contains assertion where the expected object shall be searched, using a non disjoint search.

Delegates to values(expected).

Notice that a runtime check applies which assures that only CharSequence, Number and Char are passed (this function expects Any for your convenience, so that you can mix String and Int for instance).

By non disjoint is meant that 'aa' in 'aaaa' is found three times and not only two times.

Parameters

expected - The value which is expected to be contained within the input of the search.

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

IllegalArgumentException - in case expected is not a CharSequence, Number or Char.

Return
The AssertionPlant for which the assertion was built to support a fluent API.

fun <T : CharSequence> CheckerOption<T, IgnoringCaseSearchBehaviour>.value(expected: Any): AssertionPlant<T> (source)

Finishes the specification of the sophisticated contains assertion where the expected value shall be searched (ignoring case), using a non disjoint search.

Delegates to values(expected).

Notice that a runtime check applies which assures that only CharSequence, Number and Char are passed (this function expects Any for your convenience, so that you can mix String and Int for instance).

By non disjoint is meant that 'aa' in 'aaaa' is found three times and not only two times.

Parameters

expected - The value which is expected to be contained within the input of the search.

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

IllegalArgumentException - in case expected is not a CharSequence, Number or Char.

Return
The AssertionPlant for which the assertion was built to support a fluent API.

fun <E : Any, T : Iterable<E>> CheckerOption<E, T, InAnyOrderSearchBehaviour>.value(expected: E): AssertionPlant<T> (source)

Finishes the specification of the sophisticated contains assertion where the expected value shall be searched within the Iterable.

Delegates to values(expected).

Parameters

expected - The value which is expected to be contained within the Iterable.

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

Return
The AssertionPlant for which the assertion was built to support a fluent API.

fun <E : Any, T : Iterable<E>> Builder<E, T, InAnyOrderOnlySearchBehaviour>.value(expected: E): AssertionPlant<T> (source)
fun <E : Any, T : Iterable<E>> Builder<E, T, InOrderOnlySearchBehaviour>.value(expected: E): AssertionPlant<T> (source)

Finishes the specification of the sophisticated contains assertion where the Iterable needs to contain only the expected value.

Delegates to values(expected).

Parameters

expected - The value which is expected to be contained within the Iterable.

Exceptions

AssertionError - Might throw an AssertionError if the assertion made is not correct.

Return
The AssertionPlant for which the assertion was built to support a fluent API.