kotest-core / io.kotest.core.test / executeWithAssertionsCheck

executeWithAssertionsCheck

suspend fun AssertionMode.executeWithAssertionsCheck(name: String, run: suspend () -> Unit): Unit

Executes the given run function checking for the absense of assertions according to the receiver AssertionMode.

Exceptions

ZeroAssertionsError - if the mode is AssertionMode.Error and no assertions were executed.