Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 2 of 2 for cancelLater (1.15 seconds)

  1. okhttp/src/jvmTest/kotlin/okhttp3/TrailersTest.kt

        call.execute().use { response ->
          val source = response.body.source()
          assertThat(response.header("h1")).isEqualTo("v1")
          assertThat(source.readUtf8(5)).isEqualTo("Hello")
          call.cancelLater(500.milliseconds)
          val trailersDelay =
            measureTime {
              val exception =
                assertFailsWith<IOException> {
                  response.trailers()
                }
    Created: Fri Apr 03 11:42:14 GMT 2026
    - Last Modified: Tue Jan 27 09:00:39 GMT 2026
    - 18.8K bytes
    - Click Count (0)
  2. okhttp/src/jvmTest/kotlin/okhttp3/CallTest.kt

          client.newCall(
            Request(
              server
                .url("/")
                .newBuilder()
                .scheme(scheme!!)
                .build(),
            ),
          )
        cancelLater(call, cancelDelayMillis)
        val startNanos = System.nanoTime()
        assertFailsWith<IOException> {
          call.execute()
        }
        val elapsedNanos = System.nanoTime() - startNanos
    Created: Fri Apr 03 11:42:14 GMT 2026
    - Last Modified: Sun Mar 15 09:02:18 GMT 2026
    - 146.5K bytes
    - Click Count (0)
Back to Top