- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 143 for enqueue (0.07 sec)
-
okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt
webServer.enqueue( MockResponse.Builder() .code(408) .build(), ) webServer.enqueue( MockResponse.Builder() .webSocketUpgrade(serverListener) .build(), ) val webSocket: WebSocket = newWebSocket() clientListener.assertOpen() val server = serverListener.assertOpen() webSocket.send("abc") serverListener.assertTextMessage("abc")
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Mar 31 17:16:15 UTC 2024 - 35.2K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ConnectionReuseTest.kt
} @Test fun connectionsAreReused() { server.enqueue(MockResponse(body = "a")) server.enqueue(MockResponse(body = "b")) val request = Request(server.url("/")) assertConnectionReused(request, request) } @Test fun connectionsAreReusedForPosts() { server.enqueue(MockResponse(body = "a")) server.enqueue(MockResponse(body = "b")) val request = Request(
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 12.3K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/RouteFailureTest.kt
} @Test fun http2OneBadHostOneGoodRetryOnConnectionFailure() { enableProtocol(Protocol.HTTP_2) val request = Request(server1.url("/")) server1.enqueue(refusedStream) server1.enqueue(refusedStream) server2.enqueue(bodyResponse) dns[server1.hostName] = listOf(ipv6, ipv4) socketFactory[ipv6] = server1.inetSocketAddress socketFactory[ipv4] = server2.inetSocketAddress
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue May 14 17:48:07 UTC 2024 - 11.9K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/DispatcherTest.kt
dispatcher.maxRequests = 2 client.newCall(newRequest("http://a/1")).enqueue(callback) client.newCall(newRequest("http://b/1")).enqueue(callback) client.newCall(newRequest("http://c/1")).enqueue(callback) client.newCall(newRequest("http://a/2")).enqueue(callback) client.newCall(newRequest("http://b/2")).enqueue(callback) dispatcher.maxRequests = 4
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Fri Apr 05 03:30:42 UTC 2024 - 12.7K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/WholeOperationTimeoutTest.kt
server.enqueue(MockResponse()) val request = Request.Builder() .url(server.url("/")) .post(sleepingRequestBody(500)) .build() val latch = CountDownLatch(1) val exceptionRef = AtomicReference<Throwable>() val call = client.newCall(request) call.timeout().timeout(250, TimeUnit.MILLISECONDS) call.enqueue( object : Callback {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 10.5K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/CookiesTest.kt
} @Test fun receiveAndSendMultipleCookies() { server.enqueue( MockResponse.Builder() .addHeader("Set-Cookie", "a=android") .addHeader("Set-Cookie", "b=banana") .build(), ) server.enqueue(MockResponse()) val cookieManager = CookieManager(null, CookiePolicy.ACCEPT_ORIGINAL_SERVER) client =
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 13K bytes - Viewed (0) -
mockwebserver/src/test/java/mockwebserver3/MockWebServerTest.kt
} @Disabled("Not actually failing where expected") @Test fun disconnectAtStart() { server.enqueue( MockResponse.Builder() .socketPolicy(DisconnectAtStart) .build(), ) server.enqueue(MockResponse()) // The jdk's HttpUrlConnection is a bastard. server.enqueue(MockResponse()) try { server.url("/a").toUrl().openConnection().getInputStream() fail<Unit>()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 23.5K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/DuplexTest.kt
.requestIOException() .exhaustResponse() server.enqueue( MockResponse.Builder() .clearHeaders() .code(HttpURLConnection.HTTP_MOVED_PERM) .addHeader("Location: /b") .streamHandler(body) .build(), ) server.enqueue( MockResponse.Builder() .body("this is /b") .build(), )
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 23.9K bytes - Viewed (0) -
mockwebserver-deprecated/src/test/java/okhttp3/mockwebserver/MockWebServerTest.kt
} @Disabled("Not actually failing where expected") @Test fun disconnectAtStart() { server.enqueue( MockResponse() .setSocketPolicy(SocketPolicy.DISCONNECT_AT_START), ) server.enqueue(MockResponse()) // The jdk's HttpUrlConnection is a bastard. server.enqueue(MockResponse()) try { server.url("/a").toUrl().openConnection().getInputStream() fail<Any>()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 21.9K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/ConnectionCoalescingTest.kt
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 18.7K bytes - Viewed (0)