Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for pushPromise (0.1 sec)

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

      ) {
        setUp(protocol, mockWebServer)
        val pushPromise =
          PushPromise(
            "GET",
            "/foo/bar",
            headersOf("foo", "bar"),
            MockResponse(body = "bar"),
          )
        server.enqueue(
          MockResponse.Builder()
            .body("ABCDE")
            .addPush(pushPromise)
            .build(),
        )
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 11 22:09:35 UTC 2024
    - 75.3K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/http2/Http2ConnectionTest.kt

      @Test fun doublePushPromise() {
        // Write the mocking script.
        peer.sendFrame().settings(Settings())
        peer.acceptFrame() // ACK
        peer.sendFrame().pushPromise(3, 2, headerEntries("a", "android"))
        peer.acceptFrame() // SYN_REPLY
        peer.sendFrame().pushPromise(3, 2, headerEntries("b", "banana"))
        peer.acceptFrame() // RST_STREAM
        peer.play()
    
        // Play it back.
        val connection = connect(peer)
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 75.4K bytes
    - Viewed (0)
Back to top