Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 17 for encodedPath (0.57 sec)

  1. okhttp/src/jvmTest/kotlin/okhttp3/HttpUrlTest.kt

        // next line
        assertThat(parse("http://h/\u0085").encodedPath).isEqualTo("/%C2%85")
        // non-breaking space
        assertThat(parse("http://h/\u00a0").encodedPath).isEqualTo("/%C2%A0")
        // ogham space mark
        assertThat(parse("http://h/\u1680").encodedPath).isEqualTo("/%E1%9A%80")
        // mongolian vowel separator
        assertThat(parse("http://h/\u180e").encodedPath).isEqualTo("/%E1%A0%8E")
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Mon Aug 04 07:38:48 UTC 2025
    - 69.9K bytes
    - Viewed (0)
  2. okhttp-sse/src/test/java/okhttp3/sse/internal/EventSourceHttpTest.kt

              |
              |
              """.trimMargin(),
            ).setHeader("content-type", "text/event-stream")
            .build(),
        )
        val source = newEventSource()
        assertThat(source.request().url.encodedPath).isEqualTo("/")
        listener.assertOpen()
        listener.assertEvent(null, null, "hey")
        listener.assertClose()
      }
    
      @RetryingTest(5)
      fun cancelInEventShortCircuits() {
        server.enqueue(
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 30 11:47:47 UTC 2025
    - 8.1K bytes
    - Viewed (0)
  3. mockwebserver/README.md

      assertEquals("/v1/chat/messages/", request1.getUrl().encodedPath());
      assertNotNull(request1.getHeaders().get("Authorization"));
    
      RecordedRequest request2 = server.takeRequest();
      assertEquals("/v1/chat/messages/2", request2.getUrl().encodedPath());
    
      RecordedRequest request3 = server.takeRequest();
      assertEquals("/v1/chat/messages/3", request3.getUrl().encodedPath());
    
      // Shut down the server. Instances cannot be reused.
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Jul 19 13:40:52 UTC 2025
    - 8.1K bytes
    - Viewed (0)
  4. mockwebserver/src/test/java/mockwebserver3/CustomDispatcherTest.kt

        val latch = CountDownLatch(1)
        val dispatcher: Dispatcher =
          object : Dispatcher() {
            override fun dispatch(request: RecordedRequest): MockResponse {
              if (request.url.encodedPath == firstRequest) {
                latch.await()
              }
              return MockResponse()
            }
          }
        mockWebServer.dispatcher = dispatcher
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Wed Jun 18 12:28:21 UTC 2025
    - 3.2K bytes
    - Viewed (0)
  5. okhttp/src/jvmTest/kotlin/okhttp3/KotlinSourceModernTest.kt

        val password: String = httpUrl.password
        val host: String = httpUrl.host
        val port: Int = httpUrl.port
        val pathSize: Int = httpUrl.pathSize
        val encodedPath: String = httpUrl.encodedPath
        val encodedPathSegments: List<String> = httpUrl.encodedPathSegments
        val pathSegments: List<String> = httpUrl.pathSegments
        val encodedQuery: String? = httpUrl.encodedQuery
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Jun 21 20:36:35 UTC 2025
    - 46.5K bytes
    - Viewed (0)
  6. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/http/RequestLine.kt

       * Returns the path to request, like the '/' in 'GET / HTTP/1.1'. Never empty, even if the request
       * URL is. Includes the query component if it exists.
       */
      fun requestPath(url: HttpUrl): String {
        val path = url.encodedPath
        val query = url.encodedQuery
        return if (query != null) "$path?$query" else path
      }
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Tue Jun 17 00:47:36 UTC 2025
    - 1.9K bytes
    - Viewed (0)
  7. okhttp/src/jvmTest/kotlin/okhttp3/CallKotlinTest.kt

          ),
        )
        server.enqueue(MockResponse())
    
        val request = Request(server.url("/"))
        val call = client.newCall(request)
        val response = call.execute()
    
        assertThat(response.request.url.encodedPath).isEqualTo("/b")
        assertThat(response.request.headers).isEqualTo(headersOf())
      }
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Jun 20 11:46:46 UTC 2025
    - 8.4K bytes
    - Viewed (0)
  8. okhttp/src/jvmTest/kotlin/okhttp3/InterceptorTest.kt

        client =
          client
            .newBuilder()
            .addInterceptor(
              Interceptor { chain: Interceptor.Chain ->
                if (chain.request().url.encodedPath == "/b") {
                  val requestA =
                    Request
                      .Builder()
                      .url(server.url("/a"))
                      .build()
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Jun 20 11:46:46 UTC 2025
    - 28.2K bytes
    - Viewed (0)
  9. okhttp/src/jvmTest/kotlin/okhttp3/internal/http2/HttpOverHttp2Test.kt

        assertThat(response.body.string()).isEqualTo("This is the new location!")
        val request1 = server.takeRequest()
        assertThat(request1.url.encodedPath).isEqualTo("/")
        val request2 = server.takeRequest()
        assertThat(request2.url.encodedPath).isEqualTo("/foo")
      }
    
      @ParameterizedTest
      @ArgumentsSource(ProtocolParamProvider::class)
      fun readAfterLastByte(protocol: Protocol) {
        setUp(protocol)
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Fri Jun 20 11:46:46 UTC 2025
    - 73.4K bytes
    - Viewed (0)
  10. okhttp/src/jvmTest/kotlin/okhttp3/CallTest.kt

        assertThat(connect.headers["Proxy-Authorization"]).isEqualTo(credential)
        assertThat(connect.url.encodedPath).isEqualTo("/")
        val get = server.takeRequest()
        assertThat(get.method).isEqualTo("GET")
        assertThat(get.headers["Proxy-Authorization"]).isNull()
        assertThat(get.url.encodedPath).isEqualTo("/foo")
      }
    
      @Test
      fun preemptiveThenReactiveProxyAuthentication() {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Thu Jul 31 04:18:40 UTC 2025
    - 146.6K bytes
    - Viewed (0)
Back to top