doc / ch.tutteli.atrium.api.cc.de_CH / eintraege

eintraege

fun <E : Any, T : Iterable<E?>> IterableContains.CheckerOption<E?, T, InAnyOrderSearchBehaviour>.eintraege(assertionCreatorOrNull: (Assert<E>.() -> Unit)?, vararg otherAssertionCreatorsOrNulls: (Assert<E>.() -> Unit)?): AssertionPlant<T>
Deprecated: api-cc-de_CH is discontinued, switch to api-fluent-en_GB; will be removed with 1.0.0

Finishes the specification of the sophisticated contains assertion where an entry shall be searched which either holds all assertions assertionCreatorOrNull might create or needs to be null in case assertionCreatorOrNull is defined as null -- likewise an entry (can be the same) is searched for each of the otherAssertionCreatorsOrNulls.

Parameters

assertionCreatorOrNull - The identification lambda which creates the assertions which the entry we are looking for has to hold; or in other words, the function which defines whether an entry is the one we are looking for or not. In case it is defined as null, then an entry is identified if it is null as well.

otherAssertionCreatorsOrNulls - Additional identification lambdas which each identify (separately) an entry which we are looking for (see assertionCreatorOrNull for more information).

Exceptions

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

Return
An Expect for the current subject of the assertion.

fun <E : Any, T : Iterable<E?>> IterableContains.Builder<E?, T, InAnyOrderOnlySearchBehaviour>.eintraege(assertionCreatorOrNull: (Assert<E>.() -> Unit)?, vararg otherAssertionCreatorsOrNulls: (Assert<E>.() -> Unit)?): AssertionPlant<T>
Deprecated: api-cc-de_CH is discontinued, switch to api-fluent-en_GB; will be removed with 1.0.0

Finishes the specification of the sophisticated contains assertion where an entry needs to be contained in the Iterable which holds all assertions assertionCreatorOrNull might create or needs to be null in case assertionCreatorOrNull is defined as null -- likewise an entry for each otherAssertionCreatorsOrNulls needs to be contained in the Iterable where it does not matter in which order the entries appear but only as many entries should be returned by the Iterable as assertion creators are defined.

Notice, that a first-wins strategy applies which means your assertion creator lambdas -- which kind of serve as identification lambdas -- should be ordered in such a way that the most specific identification lambda appears first, not that a less specific lambda wins. For instance, given a setOf(1, 2) you should not search for eintraege({ isGreaterThan(0) }, { toBe(1) }) but for eintraege({ toBe(1) }, { isGreaterThan(0) }) otherwise isGreaterThan(0) matches 1 before toBe(1) would match it. As a consequence toBe(1) could only match the entry which is left -- in this case 2 -- and of course this would fail.

Parameters

assertionCreatorOrNull - The identification lambda which creates the assertions which the entry we are looking for has to hold; or in other words, the function which defines whether an entry is the one we are looking for or not. In case it is defined as null, then an entry is identified if it is null as well.

otherAssertionCreatorsOrNulls - Additional identification lambdas which each identify (separately) an entry which we are looking for (see assertionCreatorOrNull for more information).

Exceptions

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

Return
An Expect for the current subject of the assertion.

fun <E : Any, T : Iterable<E?>> IterableContains.Builder<E?, T, InOrderOnlySearchBehaviour>.eintraege(assertionCreatorOrNull: (Assert<E>.() -> Unit)?, vararg otherAssertionCreatorsOrNulls: (Assert<E>.() -> Unit)?): AssertionPlant<T>
Deprecated: api-cc-de_CH is discontinued, switch to api-fluent-en_GB; will be removed with 1.0.0

Finishes the specification of the sophisticated contains assertion where the Iterable needs to contain only an entry which holds all assertions assertionCreatorOrNull might create or is null in case assertionCreatorOrNull is defined as null and likewise a further entry for each otherAssertionCreatorsOrNulls (if given) whereas the entries have to appear in the specified order.

Parameters

assertionCreatorOrNull - The identification lambda which creates the assertions which the entry we are looking for has to hold; or in other words, the function which defines whether an entry is the one we are looking for or not. In case it is defined as null, then an entry is identified if it is null as well.

otherAssertionCreatorsOrNulls - Additional identification lambdas which each identify (separately) an entry which we are looking for (see assertionCreatorOrNull for more information).

Exceptions

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

Return
An Expect for the current subject of the assertion.

fun <E : Any, T : Iterable<E>> eintraege(checkerBuilder: IterableContainsCheckerBuilder<E, T, InAnyOrderSearchBehaviour>, assertionCreator: Assert<E>.() -> Unit, vararg otherAssertionCreators: Assert<E>.() -> Unit): AssertionPlant<T>
Deprecated: Use the extension fun `eintraege` instead. This fun is only here to retain binary compatibility; will be removed with 1.0.0


fun <E : Any, T : Iterable<E>> eintraege(checkerBuilder: IterableContainsBuilder<E, T, InAnyOrderOnlySearchBehaviour>, assertionCreator: Assert<E>.() -> Unit, vararg otherAssertionCreators: Assert<E>.() -> Unit): AssertionPlant<T>
Deprecated: Use the extension fun `eintraege` instead. This fun is only here to retain binary compatibility; will be removed with 1.0.0


fun <E : Any, T : Iterable<E>> eintraege(checkerBuilder: IterableContainsBuilder<E, T, InOrderOnlySearchBehaviour>, assertionCreator: Assert<E>.() -> Unit, vararg otherAssertionCreators: Assert<E>.() -> Unit): AssertionPlant<T>
Deprecated: Use the extension fun `eintraege` instead. This fun is only here to retain binary compatibility; will be removed with 1.0.0