Joel Hess
09/14/2021, 7:37 PMsuspend fun RecommendationsExhaustedEventRepository.findByCausationIdEventually(causationId: UUID): RecommendationsExhaustedEvent {
return eventually(30.seconds, IllegalStateException::class) {
checkNotNull(
this.findByCausationId(causationId)
)
}
}
and trying to do the same thing with 4.6. FWIW, I’m also fine with leaving the eventually as is, and not moving to the new API, but I get this too: java.lang.NoSuchMethodError: 'java.lang.Object io.kotest.assertions.timing.EventuallyKt.eventually-8-LJAvk(double, kotlin.reflect.KClass, kotlin.jvm.functions.Function1, kotlin.coroutines.Continuation)'
I see that error with Kotlin 1.4.32 and 1.5.30sam
09/14/2021, 8:02 PMsam
09/14/2021, 8:02 PMJim
09/14/2021, 8:07 PMJim
09/14/2021, 8:14 PMio.kotest.framework.concurrency.eventually
does return a value:
test("eventually returns the result computed inside") {
val result = eventually(2.seconds()) {
1
}
result shouldBe 1
}
Joel Hess
09/15/2021, 1:44 AM