each

fun <T> Assert<Array<T>>.each(f: (Assert<T>) -> Unit)

Asserts on each item in the array. The given lambda will be run for each item.

assertThat(arrayOf("one", "two")).each {
it.hasLength(3)
}

fun <E> Assert<Iterable<E>>.each(f: (Assert<E>) -> Unit)

Asserts on each item in the iterable. The given lambda will be run for each item.

assertThat(listOf("one", "two")).each {
it.hasLength(3)
}

fun <E> Assert<Sequence<E>>.each(f: (Assert<E>) -> Unit)

Asserts on each item in the sequence. The given lambda will be run for each item.

assertThat(sequenceOf("one", "two")).each {
it.hasLength(3)
}