- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 134 for mockwebserver (0.08 sec)
-
samples/compare/src/test/kotlin/okhttp3/compare/JavaHttpClientTest.kt
import assertk.assertions.matches import java.net.http.HttpClient import java.net.http.HttpClient.Redirect.NORMAL import java.net.http.HttpRequest import java.net.http.HttpResponse.BodyHandlers import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import okhttp3.testing.PlatformRule import okhttp3.testing.PlatformVersion import org.junit.jupiter.api.Test import org.junit.jupiter.api.extension.RegisterExtension /**
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2.7K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/WholeOperationTimeoutTest.kt
import java.time.Duration import java.util.concurrent.CountDownLatch import java.util.concurrent.TimeUnit import java.util.concurrent.atomic.AtomicReference import kotlin.test.assertFailsWith import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import okhttp3.MediaType.Companion.toMediaTypeOrNull import okhttp3.TestUtil.repeat import okhttp3.testing.Flaky import okio.BufferedSink import org.junit.jupiter.api.BeforeEach
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 10.5K bytes - Viewed (0) -
samples/unixdomainsockets/src/main/java/okhttp3/unixdomainsockets/ClientAndServer.java
import java.util.Collections; import okhttp3.OkHttpClient; import okhttp3.Protocol; import okhttp3.Request; import okhttp3.Response; import okhttp3.mockwebserver.MockResponse; import okhttp3.mockwebserver.MockWebServer; /** * Create UNIX domain sockets for MockWebServer and OkHttp and connect 'em together. Note that we * cannot do TLS over domain sockets. */ public class ClientAndServer { public void run() throws Exception {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Dec 24 03:46:30 UTC 2018 - 2.1K bytes - Viewed (0) -
okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourcesHttpTest.kt
* See the License for the specific language governing permissions and * limitations under the License. */ package okhttp3.sse.internal import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import okhttp3.OkHttpClientTestRule import okhttp3.Request import okhttp3.sse.EventSources.processResponse import okhttp3.testing.PlatformRule import org.junit.jupiter.api.AfterEach
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Jan 14 10:20:09 UTC 2024 - 2.6K bytes - Viewed (0) -
okhttp-coroutines/src/test/kotlin/okhttp3/coroutines/ExecuteAsyncTest.kt
import kotlinx.coroutines.supervisorScope import kotlinx.coroutines.test.runTest import kotlinx.coroutines.withContext import kotlinx.coroutines.withTimeout import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import mockwebserver3.SocketPolicy.DisconnectAfterRequest import okhttp3.Callback import okhttp3.FailingCall import okhttp3.HttpUrl.Companion.toHttpUrl import okhttp3.OkHttpClientTestRule
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Thu Apr 18 01:24:38 UTC 2024 - 5.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/KotlinDeprecationErrorTest.kt
} @Test @Disabled fun mockWebServer() { val mockWebServer = MockWebServer() var port: Int = mockWebServer.getPort() mockWebServer.setServerSocketFactory(ServerSocketFactory.getDefault()) mockWebServer.setBodyLimit(0L) mockWebServer.setProtocolNegotiationEnabled(false) mockWebServer.setProtocols(listOf(Protocol.HTTP_1_1))
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/README.md
### Example Use MockWebServer the same way that you use mocking frameworks like [Mockito](https://github.com/mockito/mockito): 1. Script the mocks. 2. Run application code. 3. Verify that the expected requests were made. Here's a complete example: ```java public void test() throws Exception { // Create a MockWebServer. These are lean enough that you can create a new
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Dec 17 15:34:10 UTC 2023 - 5K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/RouteFailureTest.kt
import java.io.IOException import java.net.InetAddress import java.net.InetSocketAddress import java.net.Proxy import java.net.SocketTimeoutException import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import mockwebserver3.SocketPolicy.ResetStreamAtStart import mockwebserver3.junit5.internal.MockWebServerInstance import okhttp3.internal.http.RecordingProxySelector import okhttp3.internal.http2.ErrorCode
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/JSSETest.kt
import assertk.assertions.containsExactly import assertk.assertions.isEqualTo import assertk.assertions.isNotEmpty import javax.net.ssl.SSLSocket import javax.net.ssl.SSLSocketFactory import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import okhttp3.TestUtil.assumeNetwork import okhttp3.internal.connection import okhttp3.testing.PlatformRule import okhttp3.testing.PlatformVersion import okio.ByteString.Companion.toByteString
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sat Jan 20 10:30:28 UTC 2024 - 5.4K bytes - Viewed (0) -
okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourceHttpTest.kt
*/ package okhttp3.sse.internal import assertk.assertThat import assertk.assertions.containsExactly import assertk.assertions.isEqualTo import java.util.concurrent.TimeUnit import mockwebserver3.MockResponse import mockwebserver3.MockWebServer import okhttp3.OkHttpClientTestRule import okhttp3.RecordingEventListener import okhttp3.Request import okhttp3.sse.EventSource import okhttp3.sse.EventSources.createFactory
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Jan 14 10:20:09 UTC 2024 - 6.6K bytes - Viewed (0)