retrofit-mock / retrofit2.mock / BehaviorDelegate

BehaviorDelegate

class BehaviorDelegate<T : Any!>

Applies behavior to responses and adapts them into the appropriate return type using the call adapters of .

See Also
MockRetrofit#create(Class)

Functions

returning

fun <R : Any!> returning(call: Call<R>!): T

returningResponse

fun returningResponse(response: Any?): T