- Sort Score
- Result 10 results
- Languages All
Results 1 - 6 of 6 for MockWebServerRule (0.15 sec)
-
mockwebserver-junit4/src/main/kotlin/mockwebserver3/junit4/MockWebServerRule.kt
* the `@Rule` annotation: * * ```java * @Rule public final MockWebServerRule serverRule = new MockWebServerRule(); * ``` * * For Kotlin the `@JvmField` annotation is also necessary: * * ```kotlin * @JvmField @Rule val serverRule = MockWebServerRule() * ``` */ @ExperimentalOkHttpApi class MockWebServerRule : ExternalResource() { val server: MockWebServer = MockWebServer()
Registered: 2024-11-01 11:42 - Last Modified: 2024-01-23 14:31 - 1.8K bytes - Viewed (0) -
mockwebserver-junit4/README.md
``` @Rule public final MockWebServerRule serverRule = new MockWebServerRule(); ``` The `serverRule` field has a `server` field. It is an instance of `MockWebServer`. That instance will be shut down automatically after the test runs. For Kotlin, the `@JvmField` annotation is also necessary: ``` @JvmField @Rule val serverRule = MockWebServerRule()
Registered: 2024-11-01 11:42 - Last Modified: 2023-12-17 15:34 - 707 bytes - Viewed (0) -
mockwebserver-junit4/api/mockwebserver3-junit4.api
public final class mockwebserver3/junit4/MockWebServerRule : org/junit/rules/ExternalResource { public static final field Companion Lmockwebserver3/junit4/MockWebServerRule$Companion; public fun <init> ()V public final fun getServer ()Lmockwebserver3/MockWebServer; } public final class mockwebserver3/junit4/MockWebServerRule$Companion {
Registered: 2024-11-01 11:42 - Last Modified: 2022-02-26 19:17 - 346 bytes - Viewed (0) -
okhttp-android/src/androidTest/kotlin/okhttp3/android/AndroidAsyncDnsTest.kt
import assertk.fail import java.net.InetAddress import java.net.UnknownHostException import java.util.concurrent.CountDownLatch import mockwebserver3.MockResponse import mockwebserver3.junit4.MockWebServerRule import okhttp3.AsyncDns import okhttp3.HttpUrl.Companion.toHttpUrl import okhttp3.OkHttpClient import okhttp3.Request import okhttp3.tls.HandshakeCertificates import okhttp3.tls.HeldCertificate
Registered: 2024-11-01 11:42 - Last Modified: 2024-01-08 01:13 - 5.7K bytes - Viewed (0) -
mockwebserver-junit4/src/test/java/mockwebserver3/junit4/MockWebServerRuleTest.kt
import org.junit.Assert.fail import org.junit.Test import org.junit.runner.Description import org.junit.runners.model.Statement class MockWebServerRuleTest { @Test fun statementStartsAndStops() { val rule = MockWebServerRule() val called = AtomicBoolean() val statement: Statement = rule.apply( object : Statement() { override fun evaluate() { called.set(true)
Registered: 2024-11-01 11:42 - Last Modified: 2024-01-08 01:13 - 1.5K bytes - Viewed (0) -
docs/changelogs/changelog_2x.md
<version>1.6.0</version> </dependency> ``` * New: `Cache.initialize()`. Call this on a background thread to eagerly initialize the response cache. * New: Fold `MockWebServerRule` into `MockWebServer`. This makes it easier to write JUnit tests with `MockWebServer`. The `MockWebServer` library now depends on JUnit, though it continues to work with all testing frameworks.
Registered: 2024-11-01 11:42 - Last Modified: 2022-02-06 02:19 - 26.6K bytes - Viewed (0)