Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 14 of 14 for assertFailure (0.08 sec)

  1. okhttp/src/test/java/okhttp3/DispatcherTest.kt

      }
    
      @Test
      fun executionRejectedImmediately() {
        val request = newRequest("http://a/1")
        executor.shutdown()
        client.newCall(request).enqueue(callback)
        callback.await(request.url).assertFailure(InterruptedIOException::class.java)
        assertThat(listener.recordedEventTypes())
          .containsExactly("CallStart", "CallFailed")
      }
    
      @Test
      fun executionRejectedAfterMaxRequestsChange() {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Fri Apr 05 03:30:42 UTC 2024
    - 12.7K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/CallTest.kt

        callback.await(server.url("/0")).assertFailure("Too many follow-up requests: 21")
      }
    
      @Test
      fun http204WithBodyDisallowed() {
        server.enqueue(
          MockResponse(
            code = 204,
            body = "I'm not even supposed to be here today.",
          ),
        )
        executeSynchronously("/")
          .assertFailure("HTTP 204 had non-zero Content-Length: 39")
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Apr 10 19:46:48 UTC 2024
    - 142.5K bytes
    - Viewed (0)
  3. okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourceRecorder.kt

      }
    
      fun assertOpen(): EventSource {
        val event = nextEvent() as Open
        return event.eventSource
      }
    
      fun assertClose() {
        nextEvent() as Closed
      }
    
      fun assertFailure(message: String?) {
        val event = nextEvent() as Failure
        if (message != null) {
          assertThat(event.t!!.message).isEqualTo(message)
        } else {
          assertThat(event.t).isNull()
        }
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/RouteFailureTest.kt

            if (cleanShutdown) {
              assertSuccessful()
              assertCode(200)
    
              assertThat(server2.requestCount).isEqualTo(1)
            } else {
              this.assertFailure(SocketTimeoutException::class.java)
            }
          }
    
        println("\n\nRequest to ${server2.inetSocketAddress}")
        executeSynchronously(request)
          .assertSuccessful()
          .assertCode(200)
      }
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Tue May 14 17:48:07 UTC 2024
    - 11.9K bytes
    - Viewed (0)
Back to top