- Sort Score
- Num 10 results
- Language All
Results 1 - 6 of 6 for forbidLock (0.05 seconds)
-
okhttp/src/jvmTest/kotlin/okhttp3/ConnectionListenerTest.kt
.fastFallback(fastFallback) .build() @BeforeEach fun setUp() { platform.assumeNotOpenJSSE() platform.assumeNotBouncyCastle() listener.forbidLock(get(client.connectionPool)) listener.forbidLock(client.dispatcher) } @Test fun successfulCallEventSequence() { server.enqueue(MockResponse(body = "abc")) val call = client.newCall( Request
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-testing-support/src/main/kotlin/okhttp3/OkHttpClientTestRule.kt
.eventListenerFactory { ClientRuleEventListener(logger = ::addEvent) } .build() connectionListener.forbidLock(RealConnectionPool.get(client.connectionPool)) connectionListener.forbidLock(client.dispatcher) testClient = client } return client } private fun initialClientBuilder(): OkHttpClient.Builder = if (isLoom()) {Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Tue Nov 04 19:13:52 GMT 2025 - 10.8K bytes - Click Count (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/EventRecorder.kt
/** The timestamp of the last taken event, used to measure elapsed time between events. */ private var lastTimestampNs: Long? = null /** Confirm that the thread does not hold a lock on `lock` during the callback. */ fun forbidLock(lock: Any) { forbiddenLocks.add(lock) } /** * Removes recorded events up to (and including) an event is found whose class equals [eventClass] * and returns it. */Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Nov 05 18:28:35 GMT 2025 - 4.5K bytes - Click Count (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/RecordingConnectionListener.kt
/** The timestamp of the last taken event, used to measure elapsed time between events. */ private var lastTimestampNs: Long? = null /** Confirm that the thread does not hold a lock on `lock` during the callback. */ fun forbidLock(lock: Any) { forbiddenLocks.add(lock) } /** * Removes recorded events up to (and including) an event is found whose class equals [eventClass] * and returns it. */Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Fri May 30 21:28:20 GMT 2025 - 5.7K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/DispatcherTest.kt
.eventListenerFactory(clientTestRule.wrap(eventRecorder)) .build() @BeforeEach fun setUp() { dispatcher.maxRequests = 20 dispatcher.maxRequestsPerHost = 10 eventRecorder.forbidLock(dispatcher) } @Test fun maxRequestsZero() { assertFailsWith<IllegalArgumentException> { dispatcher.maxRequests = 0 } } @Test fun maxPerHostZero() {
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/EventListenerTest.kt
}.build() private var socksProxy: SocksProxy? = null private var cache: Cache? = null @BeforeEach fun setUp() { platform.assumeNotOpenJSSE() eventRecorder.forbidLock(get(client.connectionPool)) eventRecorder.forbidLock(client.dispatcher) } @AfterEach fun tearDown() { if (socksProxy != null) { socksProxy!!.shutdown() } if (cache != null) {
Created: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Wed Nov 05 18:28:35 GMT 2025 - 70.5K bytes - Click Count (0)