bharath154
bharath154

Reputation: 1

kotest 5.8.1 eventually block failure

is there any difference between kotest’s 5.8.0 and 5.8.1 in terms of eventually block. I see that once I update to 5.8.1 eventually blocks are failing even after changing from io.kotest.assertions.timing to io.kotest.assertions.nondeterministic I changed from eventually(5000.milliseconds(), 300.milliseconds()) to

eventuallyConfig {
    duration = 5000.milliseconds()
    interval = 300.milliseconds()
}

o I need to add some other config as well?

Tried changing to

eventually {
   eventuallyConfig {
       duration = 5000.milliseconds()
       interval = 300.milliseconds()
   }
}

but the eventually block is failing

Upvotes: 0

Views: 119

Answers (1)

sksamuel
sksamuel

Reputation: 16387

eventuallyConfig is a function that returns a config. In your second example you are creating one, but not using it anywhere.

Try this:

val config = eventuallyConfig {
   duration = 5000.milliseconds()
   interval = 300.milliseconds()
}

eventually(config) {
   
}

Upvotes: 0

Related Questions