- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 31 for recordedRequest (0.16 sec)
-
okhttp/src/test/java/okhttp3/KotlinDeprecationErrorTest.kt
val headers: Headers = pushPromise.headers() val response: MockResponse = pushPromise.response() } @Test @Disabled fun recordedRequest() { val recordedRequest = RecordedRequest("", Headers.of(), listOf(), 0L, Buffer(), 0, Socket()) var utf8Body: String = recordedRequest.utf8Body } @Test @Disabled fun request() { val request: Request = Request.Builder().build()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 13.3K bytes - Viewed (0) -
mockwebserver-deprecated/src/main/kotlin/okhttp3/mockwebserver/MockWebServer.kt
delegate.requireClientAuth() } @Throws(InterruptedException::class) fun takeRequest(): RecordedRequest { return delegate.takeRequest().unwrap() } @Throws(InterruptedException::class) fun takeRequest( timeout: Long, unit: TimeUnit, ): RecordedRequest? { return delegate.takeRequest(timeout, unit)?.unwrap() } @JvmName("-deprecated_requestCount")
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue Jan 23 14:31:42 UTC 2024 - 5.9K bytes - Viewed (0) -
mockwebserver/src/main/kotlin/mockwebserver3/Dispatcher.kt
/** * Returns a response to satisfy `request`. This method may block (for instance, to wait on * a CountdownLatch). */ @Throws(InterruptedException::class) abstract fun dispatch(request: RecordedRequest): MockResponse /** * Returns an early guess of the next response, used for policy on how an incoming request should * be received. The default implementation returns an empty response. Mischievous implementations
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue Jan 23 14:31:42 UTC 2024 - 1.7K bytes - Viewed (0) -
mockwebserver/src/main/kotlin/mockwebserver3/QueueDispatcher.kt
protected val responseQueue: BlockingQueue<MockResponse> = LinkedBlockingQueue() private var failFastResponse: MockResponse? = null @Throws(InterruptedException::class) override fun dispatch(request: RecordedRequest): MockResponse { // To permit interactive/browser testing, ignore requests for favicons. val requestLine = request.requestLine if (requestLine == "GET /favicon.ico HTTP/1.1") {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue Jan 23 14:31:42 UTC 2024 - 3K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/ws/WebSocketHttpTest.kt
import java.util.concurrent.atomic.AtomicInteger import kotlin.test.assertFailsWith import mockwebserver3.Dispatcher import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import mockwebserver3.RecordedRequest import mockwebserver3.SocketPolicy import mockwebserver3.SocketPolicy.KeepOpen import mockwebserver3.SocketPolicy.NoResponse import okhttp3.Interceptor import okhttp3.OkHttpClient import okhttp3.OkHttpClientTestRule
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/internal/http2/HttpOverHttp2Test.kt
server.enqueue(MockResponse()) val call = client.newCall(Request(server.url("/"))) val response = call.execute() assertThat(response.body.string()).isEqualTo("") val recordedRequest = server.takeRequest() assertThat(recordedRequest.headers[":authority"]).isEqualTo("privateobject.com") } private fun gzip(bytes: String): Buffer { val bytesOut = Buffer() val sink = GzipSink(bytesOut).buffer()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 11 22:09:35 UTC 2024 - 75.3K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/URLConnectionTest.kt
response.body.byteStream().close() val recordedRequest1 = server.takeRequest() assertThat(recordedRequest1.method).isEqualTo("POST") assertThat(recordedRequest1.body.readUtf8()).isEqualTo(body) assertThat(recordedRequest1.headers["Authorization"]).isNull() val recordedRequest2 = server.takeRequest() assertThat(recordedRequest2.method).isEqualTo("POST")
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 131.7K bytes - Viewed (0) -
mockwebserver/src/test/java/mockwebserver3/MockWebServerTest.kt
proxiedClient.newCall(request).execute().use { response -> assertThat(response.body.string()).isEqualTo("Result") } val recordedRequest = server.takeRequest() assertThat(recordedRequest.requestUrl).isEqualTo("http://android.com/".toHttpUrl()) } @Test fun startTwice() { val server2 = MockWebServer() server2.start() server2.start()
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/CacheTest.kt
val response1 = client.newCall(request1).execute() assertThat(response1.body.string()).isEqualTo("ABC") val recordedRequest1 = server.takeRequest() assertThat(recordedRequest1.requestLine).isEqualTo("GET /foo HTTP/1.1") assertThat(recordedRequest1.sequenceNumber).isEqualTo(0) val request2 = Request.Builder().url(server.url("/bar")).build() val response2 = client.newCall(request2).execute()
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Wed Apr 10 19:46:48 UTC 2024 - 108.6K bytes - Viewed (0) -
CHANGELOG.md
* New: `mockwebserver3.MockResponseBody` for streamed response bodies. * New: `mockwebserver3.MockResponse` is now immutable, with a `Builder`. * New: `mockwebserver3.RecordedRequest.handshakeServerNames` returns the SNI (Server Name Indication) attribute from the TLS handshake. * Upgrade: [Kotlin 1.9.21][kotlin_1_9_21]. * Upgrade: [Okio 3.7.0][okio_3_7_0].
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 18 01:31:39 UTC 2024 - 21.4K bytes - Viewed (0)