Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 63 for assertFailsWith (0.15 sec)

  1. okhttp/src/test/java/okhttp3/internal/cache/DiskLruCacheTest.kt

      private fun Editor.assertInoperable() {
        assertFailsWith<IllegalStateException> {
          setString(0, "A")
        }
        assertFailsWith<IllegalStateException> {
          newSource(0)
        }
        assertFailsWith<IllegalStateException> {
          newSink(0)
        }
        assertFailsWith<IllegalStateException> {
          commit()
        }
        assertFailsWith<IllegalStateException> {
          abort()
        }
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Apr 15 14:55:09 UTC 2024
    - 75.8K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/CallTest.kt

        val requestBuilder = Request.Builder()
        assertFailsWith<IllegalArgumentException> {
          requestBuilder.url("ftp://hostname/path")
        }.also { expected ->
          assertThat(expected.message).isEqualTo("Expected URL scheme 'http' or 'https' but was 'ftp'")
        }
      }
    
      @Test
      fun invalidPort() {
        val requestBuilder = Request.Builder()
        assertFailsWith<IllegalArgumentException> {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Apr 10 19:46:48 UTC 2024
    - 142.5K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/internal/http/StatusLineTest.kt

     * limitations under the License.
     */
    package okhttp3.internal.http
    
    import assertk.assertThat
    import assertk.assertions.isEqualTo
    import java.net.ProtocolException
    import kotlin.test.assertFailsWith
    import okhttp3.Protocol
    import okhttp3.internal.http.StatusLine.Companion.parse
    import org.junit.jupiter.api.Test
    
    class StatusLineTest {
      @Test
      fun parse() {
        val message = "Temporary Redirect"
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  4. okhttp/src/test/java/okhttp3/CertificateChainCleanerTest.kt

     */
    package okhttp3
    
    import assertk.assertThat
    import assertk.assertions.isEqualTo
    import java.security.cert.Certificate
    import javax.net.ssl.SSLPeerUnverifiedException
    import kotlin.test.assertFailsWith
    import okhttp3.internal.tls.CertificateChainCleaner.Companion.get
    import okhttp3.tls.HandshakeCertificates
    import okhttp3.tls.HeldCertificate
    import org.junit.jupiter.api.Test
    
    class CertificateChainCleanerTest {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 9.3K bytes
    - Viewed (0)
  5. okhttp/src/test/java/okhttp3/HttpUrlTest.kt

      }
    
      @Test
      fun incompleteUrlComposition() {
        val noHost =
          assertFailsWith<IllegalStateException> {
            HttpUrl.Builder().scheme("http").build()
          }
        assertThat(noHost.message).isEqualTo("host == null")
        val noScheme =
          assertFailsWith<IllegalStateException> {
            HttpUrl.Builder().host("host").build()
          }
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 67.9K bytes
    - Viewed (0)
  6. okhttp/src/test/java/okhttp3/internal/idn/IdnaMappingTableTest.kt

        assertThat("⑴".map()).isEqualTo("(1)")
      }
    
      @Test fun outOfBounds() {
        assertFailsWith<IllegalArgumentException> {
          table.map(-1, Buffer())
        }
        table.map(0, Buffer()) // Lowest legal code point.
        table.map(0x10ffff, Buffer()) // Highest legal code point.
        assertFailsWith<IllegalArgumentException> {
          table.map(0x110000, Buffer())
        }
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  7. okhttp/src/test/java/okhttp3/internal/tls/CertificatePinnerChainValidationTest.kt

    import javax.net.ssl.KeyManager
    import javax.net.ssl.SSLHandshakeException
    import javax.net.ssl.SSLPeerUnverifiedException
    import javax.net.ssl.SSLSocketFactory
    import javax.net.ssl.TrustManager
    import kotlin.test.assertFailsWith
    import mockwebserver3.MockResponse
    import mockwebserver3.MockWebServer
    import mockwebserver3.SocketPolicy.DisconnectAtEnd
    import okhttp3.CertificatePinner
    import okhttp3.CertificatePinner.Companion.pin
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 23.8K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/internal/http2/HpackTest.kt

    import assertk.assertThat
    import assertk.assertions.containsExactly
    import assertk.assertions.isEqualTo
    import assertk.assertions.isNull
    import java.io.IOException
    import java.util.Arrays
    import kotlin.test.assertFailsWith
    import okhttp3.TestUtil.headerEntries
    import okio.Buffer
    import okio.ByteString
    import okio.ByteString.Companion.decodeHex
    import okio.ByteString.Companion.encodeUtf8
    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
    - 38.2K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/internal/http2/HttpOverHttp2Test.kt

    import java.util.concurrent.TimeUnit
    import java.util.concurrent.TimeoutException
    import java.util.concurrent.atomic.AtomicReference
    import javax.net.ssl.SSLException
    import kotlin.test.assertFailsWith
    import mockwebserver3.Dispatcher
    import mockwebserver3.MockResponse
    import mockwebserver3.MockWebServer
    import mockwebserver3.PushPromise
    import mockwebserver3.QueueDispatcher
    import mockwebserver3.RecordedRequest
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 11 22:09:35 UTC 2024
    - 75.3K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/FastFallbackTest.kt

    import java.net.Inet6Address
    import java.net.InetAddress
    import java.net.Socket
    import java.util.concurrent.CountDownLatch
    import java.util.concurrent.TimeUnit
    import javax.net.SocketFactory
    import kotlin.test.assertFailsWith
    import mockwebserver3.MockResponse
    import mockwebserver3.MockWebServer
    import mockwebserver3.SocketPolicy.ResetStreamAtStart
    import okhttp3.internal.http2.ErrorCode
    import okhttp3.testing.Flaky
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 10.3K bytes
    - Viewed (0)
Back to top