doc / ch.tutteli.atrium.api.infix.en_GB / asIterable

asIterable

infix fun <E, T : Sequence<E>> Expect<T>.asIterable(o: o): Expect<Iterable<E>> (source)

Turns Expect<E, T : Sequence<E>> into Expect<Iterable<E>>.

The transformation as such is not reflected in reporting. Use feature { f(it::asIterable) } if you want to show the transformation in reporting.

Return
The newly created Expect for the transformed subject.

infix fun <E, T : Sequence<E>> Expect<T>.asIterable(assertionCreator: Expect<Iterable<E>>.() -> Unit): Expect<T> (source)

Expects that the subject of this expectation holds all assertions the given assertionCreator creates for the subject as Iterable.

The transformation as such is not reflected in reporting. Use feature of({ f(it::asIterable) }, assertionCreator) if you want to show the transformation in reporting.

Return
an Expect for the subject of this expectation.