main.misk.mockito.MockitoExtensions.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of misk-testing Show documentation
Show all versions of misk-testing Show documentation
Open source application container in Kotlin
package misk.mockito
import org.mockito.ArgumentCaptor
import org.mockito.Mockito
import org.mockito.Mockito.`when`
import org.mockito.stubbing.OngoingStubbing
object Mockito {
inline fun mock(): T = Mockito.mock(T::class.java)
inline fun whenever(t: T): OngoingStubbing = `when`(t)
inline fun captor(): ArgumentCaptor = ArgumentCaptor.forClass(T::class.java)
}