Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for mocked (0.15 sec)

  1. okhttp/src/test/java/okhttp3/internal/http2/HttpOverHttp2Test.kt

        mockWebServer: MockWebServer,
      ) {
        setUp(protocol, mockWebServer)
        server.enqueue(
          MockResponse(
            code = HttpURLConnection.HTTP_MOVED_TEMP,
            headers = headersOf("Location", "/foo"),
            body = "This page has moved!",
          ),
        )
        server.enqueue(MockResponse(body = "This is the new location!"))
        val call = client.newCall(Request(server.url("/")))
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Thu Apr 11 22:09:35 GMT 2024
    - 75.3K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/http2/Http2ConnectionTest.kt

        peer.play()
        val longString = repeat('a', Http2.INITIAL_MAX_FRAME_SIZE + 1)
        val socket = peer.openSocket()
        val connection =
          Http2Connection.Builder(true, TaskRunner.INSTANCE)
            .socket(socket)
            .pushObserver(IGNORE)
            .build()
        connection.start(sendConnectionPreface = false)
        socket.shutdownOutput()
        assertFailsWith<IOException> {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 75.4K bytes
    - Viewed (0)
Back to top