Eric
01/25/2022, 1:35 PMfun <T> T.assertIsSuccessful(
dataAssertion: (Assertion.Builder<T>.() -> Unit)? = null
): T = expectThat(this)
// removed for brevity
.and { dataAssertion?.invoke(this) ?: assert(true) } // this ?
.also { data -> dataAssertion?.invoke(data) } // or this?
.subject
or is there a better way than either of those two?