Hey there! Is there alternative to Mockito’s `clea...
# mockk
v
Hey there! Is there alternative to Mockito’s
clearInvocations
in mockk? (clear invocation log without resetting the stubbing)
t
clearAllMocks(answers = false)
should do what you ask. have a look at the other options for
clearAllMocks
as well
🙏 2
v
thank you!
l
You can also consider the
clearMocks
call with the same
answers= false
, which requires you to pass all mocks that should be cleared. This is a bit more forgiving when one day you want to run your tests in parallel.