Basically instead of relying on the old `testMode`...
# kotlin-fuel
Basically instead of relying on the old
with blocking = true, which doesn't alllow us to test asynchronousliness, my refactor where only async requests are cancellable can now "wait" inline:
Copy code
    fun gsonTestResponseObjectAsync() {
        var isAsync = false
        val running = reflectedRequest(Method.GET, "user-agent")
            .responseObject(gsonDeserializerOf( { _, _, result ->
                val (data, error) = result
                assertThat("Expected data, actual error $error", data, notNullValue())
                assertThat("Expected data to have a user agent", data!!.userAgent, notNullValue())
                assertThat("Expected isAsync to be true, actual false", isAsync, equalTo(true))

        isAsync = true

        assertThat(running.isDone, equalTo(true))
        assertThat(running.isCancelled, equalTo(false))