- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 517 for assertThat (0.52 sec)
-
android-test/src/androidTest/java/okhttp/android/test/sni/SniOverrideTest.kt
.header("Host", "cloudflare-dns.com") .build() client.newCall(request).execute().use { response -> assertThat(response.code).isEqualTo(200) assertThat(response.protocol).isEqualTo(Protocol.HTTP_2) assertThat(response.body.string()).contains("h=cloudflare-dns.com") } } @Test fun getWithDns() { client = client .newBuilder()
Registered: Fri Dec 26 11:42:13 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 3.6K bytes - Viewed (0) -
samples/compare/src/test/kotlin/okhttp3/compare/ApacheHttpClientTest.kt
assertThat(response.code).isEqualTo(200) assertThat(EntityUtils.toString(response.entity)).isEqualTo("hello, Apache HttpClient 5.x") } val recorded = server.takeRequest() assertThat(recorded.headers["Accept"]).isEqualTo("text/plain") assertThat(recorded.headers["Accept-Encoding"]).isEqualTo("gzip, x-gzip, deflate")
Registered: Fri Dec 26 11:42:13 UTC 2025 - Last Modified: Wed Jun 18 12:28:21 UTC 2025 - 2.1K bytes - Viewed (0) -
src/test/java/org/codelibs/core/beans/impl/PropertyDescImplTest.java
final BeanDesc beanDesc = new BeanDescImpl(moge.getClass()); final PropertyDesc propDesc = beanDesc.getPropertyDesc("name"); assertThat(propDesc, is(notNullValue())); assertThat((String) propDesc.getValue(moge), is("moge")); } /** * */ public static class MyBean { private int fff_; private BigDecimal ggg_;
Registered: Sat Dec 20 08:55:33 UTC 2025 - Last Modified: Fri Jun 20 13:40:57 UTC 2025 - 11K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/escape/ArrayBasedUnicodeEscaperTest.java
return NO_CHARS; } }; EscaperAsserts.assertBasic(escaper); assertThat(escaper.escape("\tFish & Chips\n")).isEqualTo("<tab>Fish <and> Chips<newline>"); // Verify that everything else is left unescaped. String safeChars = "\0\u0100\uD800\uDC00\uFFFF"; assertThat(escaper.escape(safeChars)).isEqualTo(safeChars);Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Feb 18 15:41:04 UTC 2025 - 5.2K bytes - Viewed (0) -
src/test/java/org/codelibs/core/collection/SingleValueIteratorTest.java
import static org.junit.Assert.assertThat; import org.junit.Test; /** * @author koichik * */ public class SingleValueIteratorTest { /** * */ @Test public void test() { final SingleValueIterator<String> it = new SingleValueIterator<String>("Foo"); assertThat(it.hasNext(), is(true)); assertThat(it.next(), is("Foo"));Registered: Sat Dec 20 08:55:33 UTC 2025 - Last Modified: Sat May 10 01:32:17 UTC 2025 - 1.1K bytes - Viewed (0) -
okhttp-testing-support/src/main/kotlin/okhttp3/RecordingConnectionListener.kt
val actualElapsedNs = result.timestampNs - (lastTimestampNs ?: result.timestampNs) lastTimestampNs = result.timestampNs if (eventClass != null) { assertThat(result).isInstanceOf(eventClass) } if (elapsedMs != -1L) { assertThat( TimeUnit.NANOSECONDS .toMillis(actualElapsedNs) .toDouble(), ).isCloseTo(elapsedMs.toDouble(), 100.0) } return resultRegistered: Fri Dec 26 11:42:13 UTC 2025 - Last Modified: Fri May 30 21:28:20 UTC 2025 - 5.7K bytes - Viewed (0) -
okhttp/src/commonTest/kotlin/okhttp3/internal/publicsuffix/PublicSuffixDatabaseTest.kt
// A wildcard rule, let's replace the wildcard with a value. publicSuffix = publicSuffix.replace("\\*".toRegex(), "square") } assertThat(publicSuffixDatabase.getEffectiveTldPlusOne(publicSuffix)).isNull() val test = "foobar.$publicSuffix" assertThat(publicSuffixDatabase.getEffectiveTldPlusOne(test)).isEqualTo(test) } } @Test fun publicSuffixExceptions() { val buffer = Buffer()
Registered: Fri Dec 26 11:42:13 UTC 2025 - Last Modified: Tue May 27 22:00:49 UTC 2025 - 8.5K bytes - Viewed (0) -
src/test/java/org/codelibs/core/io/ResourceBundleUtilTest.java
System.out.println(value); assertThat(value, is(notNullValue())); } /** * @throws Exception */ @Test public void testGetBundle() throws Exception { final ResourceBundle bundle = ResourceBundleUtil.getBundle("CLMessages", null, this.getClass().getClassLoader()); assertThat(bundle, is(notNullValue())); } /** * @throws Exception
Registered: Sat Dec 20 08:55:33 UTC 2025 - Last Modified: Sat May 10 01:32:17 UTC 2025 - 1.8K bytes - Viewed (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/ws/WebSocketWriterTest.kt
}.also { expected -> assertThat(expected.message).isEqualTo("Code must be in range [1000,5000): 98724976") } } @Test fun closeReservedThrows() { assertFailsWith<IllegalArgumentException> { clientWriter.writeClose(1005, "Hello".encodeUtf8()) }.also { expected -> assertThat(expected.message).isEqualTo("Code 1005 is reserved and may not be used.") }Registered: Fri Dec 26 11:42:13 UTC 2025 - Last Modified: Fri Dec 27 13:39:56 UTC 2024 - 9.3K bytes - Viewed (0) -
src/test/java/org/codelibs/core/text/JsonUtilTest.java
package org.codelibs.core.text; import static org.hamcrest.core.Is.is; import static org.junit.Assert.assertThat; import org.junit.Test; /** * @author shinsuke * */ public class JsonUtilTest { @Test public void escape() { assertThat(JsonUtil.escape("abc123あア亜"), is("abc123あア亜")); assertThat(JsonUtil.escape("\\\"/\b\t\n\f\r\0"), is("\\\\\\\"\\/\\b\\t\\n\\f\\r\\u0000")); }Registered: Sat Dec 20 08:55:33 UTC 2025 - Last Modified: Sat May 10 01:32:17 UTC 2025 - 1K bytes - Viewed (0)