- Sort Score
- Num 10 results
- Language All
Results 21 - 30 of 32 for newClientBuilder (0.13 seconds)
-
okhttp/src/jvmTest/kotlin/okhttp3/ConnectionListenerTest.kt
private val handshakeCertificates = localhost() open val fastFallback: Boolean get() = true private var client: OkHttpClient = clientTestRule .newClientBuilder() .connectionPool(ConnectionPool(connectionListener = listener)) .fastFallback(fastFallback) .build() @BeforeEach fun setUp() { platform.assumeNotOpenJSSE()
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 18:33:48 GMT 2025 - 9.7K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/TrailersTest.kt
@RegisterExtension val clientTestRule = OkHttpClientTestRule() @StartStop private val server = MockWebServer() private var client = clientTestRule .newClientBuilder() .cache(Cache(fileSystem, "/cache/".toPath(), Long.MAX_VALUE)) .build() @Test fun trailersHttp1() { trailers(Protocol.HTTP_1_1) } @Test fun trailersHttp2() {
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Sat Nov 08 21:45:04 GMT 2025 - 18.8K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/FastFallbackTest.kt
dnsResults = listOf( localhostIpv4, localhostIpv6, ) client = clientTestRule .newClientBuilder() .eventListenerFactory(clientTestRule.wrap(eventRecorder)) .connectTimeout(60, TimeUnit.SECONDS) // Deliberately exacerbate slow fallbacks. .dns { dnsResults } .fastFallback(true)Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 10.6K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/ConnectionCoalescingTest.kt
val handshakeCertificates = HandshakeCertificates .Builder() .addTrustedCertificate(rootCa.certificate) .build() client = clientTestRule .newClientBuilder() .fastFallback(false) // Avoid data races. .dns(dns) .sslSocketFactory( handshakeCertificates.sslSocketFactory(), handshakeCertificates.trustManager,Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Thu Jun 19 11:44:16 GMT 2025 - 19.1K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/DispatcherTest.kt
val webSocketListener = object : WebSocketListener() { } val dispatcher = Dispatcher(executor) val eventRecorder = EventRecorder() var client = clientTestRule .newClientBuilder() .dns { throw UnknownHostException() } .dispatcher(dispatcher) .eventListenerFactory(clientTestRule.wrap(eventRecorder)) .build() @BeforeEach fun setUp() {Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 15.8K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/DuplexTest.kt
private val server = MockWebServer() private var eventRecorder = EventRecorder() private val handshakeCertificates = platform.localhostHandshakeCertificates() private var client = clientTestRule .newClientBuilder() .eventListenerFactory(clientTestRule.wrap(eventRecorder)) .build() private val executorService = Executors.newScheduledThreadPool(1) @BeforeEach fun setUp() {
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 25.8K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/ws/WebSocketHttpTest.kt
private val clientListener = WebSocketRecorder("client") private val serverListener = WebSocketRecorder("server") private val random = Random(0) private var client = clientTestRule .newClientBuilder() .writeTimeout(Duration.ofMillis(500)) .readTimeout(Duration.ofMillis(500)) .addInterceptor( Interceptor { chain: Interceptor.Chain ->
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 35.5K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/CallTest.kt
private var eventRecorder = EventRecorder() private val handshakeCertificates = platform.localhostHandshakeCertificates() private var client = clientTestRule .newClientBuilder() .eventListenerFactory(clientTestRule.wrap(eventRecorder)) .build() private val callback = RecordingCallback() private val cache = Cache( fileSystem = LoggingFilesystem(fileSystem),
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 147.4K bytes - Click Count (0) -
android-test/src/androidTest/java/okhttp/android/test/OkHttpTest.kt
public val clientTestRule = OkHttpClientTestRule().apply { logger = Logger.getLogger(OkHttpTest::class.java.name) } private var client: OkHttpClient = clientTestRule .newClientBuilder() .addInterceptor(CompressionInterceptor(Zstd, Brotli, Gzip)) .build() private val moshi = Moshi .Builder() .add(KotlinJsonAdapterFactory()) .build()Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 29.9K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/HttpOverHttp2Test.kt
if (protocol === Protocol.HTTP_2) { platform.assumeHttp2Support() server.useHttps(handshakeCertificates.sslSocketFactory()) client = clientTestRule .newClientBuilder() .protocols(listOf(Protocol.HTTP_2, Protocol.HTTP_1_1)) .sslSocketFactory( handshakeCertificates.sslSocketFactory(), handshakeCertificates.trustManager,
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Sat Nov 01 12:18:11 GMT 2025 - 67.4K bytes - Click Count (0)