projects
/
Sone.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add some nullability annotations to Sone and profile
[Sone.git]
/
src
/
test
/
kotlin
/
net
/
pterodactylus
/
sone
/
test
/
Mockotlin.kt
diff --git
a/src/test/kotlin/net/pterodactylus/sone/test/Mockotlin.kt
b/src/test/kotlin/net/pterodactylus/sone/test/Mockotlin.kt
index
dada6eb
..
4549641
100644
(file)
--- a/
src/test/kotlin/net/pterodactylus/sone/test/Mockotlin.kt
+++ b/
src/test/kotlin/net/pterodactylus/sone/test/Mockotlin.kt
@@
-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> 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>())
inline fun <reified T : Any> OngoingStubbing<T>.thenReturnMock(): OngoingStubbing<T> = this.thenReturn(mock<T>())