- Sort Score
- Result 10 results
- Languages All
Results 51 - 60 of 749 for header_2 (0.07 sec)
-
tests/test_tutorial/test_bigger_applications/test_main_an_py39.py
response = client.get("/items?token=jessica", headers={"X-Token": "invalid"}) assert response.status_code == 400 assert response.json() == {"detail": "X-Token header invalid"} @needs_py39 def test_items_bar_with_invalid_token(client: TestClient): response = client.get("/items/bar?token=jessica", headers={"X-Token": "invalid"}) assert response.status_code == 400
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Apr 18 19:40:57 UTC 2024 - 24.9K bytes - Viewed (0) -
tests/test_tutorial/test_header_param_models/test_tutorial002.py
mod = importlib.import_module(f"docs_src.header_param_models.{request.param}") client = TestClient(mod.app) client.headers.clear() return client def test_header_param_model(client: TestClient): response = client.get( "/items/", headers=[ ("save-data", "true"), ("if-modified-since", "yesterday"), ("traceparent", "123"),
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Sep 17 18:54:10 UTC 2024 - 9.5K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/http/BridgeInterceptor.kt
transparentGzip = true requestBuilder.header("Accept-Encoding", "gzip") } val cookies = cookieJar.loadForRequest(userRequest.url) if (cookies.isNotEmpty()) { requestBuilder.header("Cookie", cookieHeader(cookies)) } if (userRequest.header("User-Agent") == null) { requestBuilder.header("User-Agent", USER_AGENT) }
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 4.2K bytes - Viewed (0) -
mockwebserver/src/main/kotlin/mockwebserver3/MockWebServer.kt
for (pushPromise in promises) { val pushedHeaders = mutableListOf<Header>() pushedHeaders.add(Header(Header.TARGET_AUTHORITY, url(pushPromise.path).host)) pushedHeaders.add(Header(Header.TARGET_METHOD, pushPromise.method)) pushedHeaders.add(Header(Header.TARGET_PATH, pushPromise.path)) val pushPromiseHeaders = pushPromise.headers for ((name, value) in pushPromiseHeaders) {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Sun Mar 31 17:16:15 UTC 2024 - 37.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/internal/http2/Http2Test.kt
) } @Test fun pushPromise() { val expectedPromisedStreamId = 11 val pushPromise = listOf( Header(Header.TARGET_METHOD, "GET"), Header(Header.TARGET_SCHEME, "https"), Header(Header.TARGET_AUTHORITY, "squareup.com"), Header(Header.TARGET_PATH, "/"), ) // Write the push promise frame, specifying the associated stream ID.
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 28.1K bytes - Viewed (0) -
tests/test_tutorial/test_dependencies/test_tutorial006.py
} ) def test_get_invalid_one_header(): response = client.get("/items/", headers={"X-Token": "invalid"}) assert response.status_code == 400, response.text assert response.json() == {"detail": "X-Token header invalid"} def test_get_invalid_second_header(): response = client.get( "/items/", headers={"X-Token": "fake-super-secret-token", "X-Key": "invalid"} )
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Apr 18 19:40:57 UTC 2024 - 5K bytes - Viewed (0) -
docs_src/app_testing/app_b_py310/test_main.py
def test_read_nonexistent_item(): response = client.get("/items/baz", headers={"X-Token": "coneofsilence"}) assert response.status_code == 404 assert response.json() == {"detail": "Item not found"} def test_create_item(): response = client.post( "/items/", headers={"X-Token": "coneofsilence"},
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Wed Mar 13 19:07:10 UTC 2024 - 1.8K bytes - Viewed (0) -
internal/crypto/header_test.go
RemoveSensitiveHeaders(test.Header) if !isEqual(test.ExpectedHeader, test.Header) { t.Errorf("Test %d: filtered headers do not match expected headers - got: %v , want: %v", i, test.Header, test.ExpectedHeader) } RemoveSensitiveEntries(metadata) if !areKeysEqual(test.ExpectedHeader, metadata) { t.Errorf("Test %d: filtered headers do not match expected headers - got: %v , want: %v", i, test.Header, test.ExpectedHeader) } }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jul 13 14:52:15 UTC 2022 - 21.4K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/RequestTest.kt
val body = "hello".toRequestBody() val headers = headersOf("User-Agent", "RequestTest") val method = "PUT" val request = Request( url = url, headers = headers, method = method, body = body, ) assertThat(request.url).isEqualTo(url) assertThat(request.headers).isEqualTo(headers) assertThat(request.method).isEqualTo(method)
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 16.4K bytes - Viewed (0) -
docs_src/app_testing/app_b/test_main.py
def test_read_nonexistent_item(): response = client.get("/items/baz", headers={"X-Token": "coneofsilence"}) assert response.status_code == 404 assert response.json() == {"detail": "Item not found"} def test_create_item(): response = client.post( "/items/", headers={"X-Token": "coneofsilence"},
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Wed Mar 13 19:07:10 UTC 2024 - 1.8K bytes - Viewed (0)