Add some nullability annotations to Sone and profile
[Sone.git] / src / test / kotlin / net / pterodactylus / sone / test / Mockotlin.kt
index dada6eb..4549641 100644 (file)
@@ -17,6 +17,6 @@ inline fun <reified T : Any> bind(implementation: T): Module =
 inline fun <reified T : Any> bindMock(): Module =
                Module { it!!.bind(T::class.java).toInstance(mock<T>()) }
 
-inline fun <reified T: Any> whenever(methodCall: T) = Mockito.`when`(methodCall)
+inline fun <reified T: Any?> whenever(methodCall: T) = Mockito.`when`(methodCall)!!
 
 inline fun <reified T : Any> OngoingStubbing<T>.thenReturnMock(): OngoingStubbing<T> = this.thenReturn(mock<T>())