- Sort Score
- Result 10 results
- Languages All
Results 331 - 340 of 1,948 for clientX (0.1 sec)
-
tests/test_response_model_data_filter_no_inheritance.py
return [pet1, pet2] client = TestClient(app) def test_filter_top_level_model(): response = client.post( "/users", json={"email": "******@****.***", "password": "secret"} ) assert response.json() == {"email": "******@****.***"} def test_filter_second_level_model(): response = client.get("/pets/1") assert response.json() == {
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 1.7K bytes - Viewed (0) -
tests/test_tutorial/test_handling_errors/test_tutorial002.py
from docs_src.handling_errors.tutorial002 import app client = TestClient(app) def test_get_item_header(): response = client.get("/items-header/foo") assert response.status_code == 200, response.text assert response.json() == {"item": "The Foo Wrestlers"} def test_get_item_not_found_header(): response = client.get("/items-header/bar") assert response.status_code == 404, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 3.3K bytes - Viewed (0) -
docs/sts/dex.yaml
# Uncommend the passwordConnector to use a specific connector for password grants passwordConnector: local # Instead of reading from an external storage, use this list of clients. # # If this option isn't chosen clients may be added through the gRPC API. staticClients: - id: example-app redirectURIs: - 'http://localhost:8080/oauth2/callback' name: 'Example App' secret: ZXhhbXBsZS1hcHAtc2VjcmV0
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jul 15 11:55:55 UTC 2020 - 2.7K bytes - Viewed (0) -
tests/test_tutorial/test_request_files/test_tutorial001_03_an.py
from fastapi.testclient import TestClient from docs_src.request_files.tutorial001_03_an import app client = TestClient(app) def test_post_file(tmp_path): path = tmp_path / "test.txt" path.write_bytes(b"<file content>") client = TestClient(app) with path.open("rb") as file: response = client.post("/files/", files={"file": file}) assert response.status_code == 200, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 6K bytes - Viewed (0) -
okhttp/src/test/java/okhttp3/RouteFailureTest.kt
} private fun enableProtocol(protocol: Protocol) { enableTls() client = client.newBuilder() .protocols(listOf(protocol, Protocol.HTTP_1_1)) .build() server1.protocols = client.protocols server2.protocols = client.protocols } private fun enableTls() { client = client.newBuilder() .sslSocketFactory(
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Tue May 14 17:48:07 UTC 2024 - 11.9K bytes - Viewed (0) -
tests/test_tutorial/test_request_files/test_tutorial001_02_an_py310.py
from fastapi.testclient import TestClient from ...utils import needs_py310 @pytest.fixture(name="client") def get_client(): from docs_src.request_files.tutorial001_02_an_py310 import app client = TestClient(app) return client @needs_py310 def test_post_form_no_body(client: TestClient): response = client.post("/files/") assert response.status_code == 200, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 8.5K bytes - Viewed (0) -
tests/test_tutorial/test_custom_docs_ui/test_tutorial002.py
@pytest.fixture(scope="module") def client(): static_dir: Path = Path(os.getcwd()) / "static" print(static_dir) static_dir.mkdir(exist_ok=True) from docs_src.custom_docs_ui.tutorial002 import app with TestClient(app) as client: yield client static_dir.rmdir() def test_swagger_ui_html(client: TestClient): response = client.get("/docs")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Aug 19 19:54:04 UTC 2023 - 1.2K bytes - Viewed (0) -
tests/test_tutorial/test_dependencies/test_tutorial008c_an_py39.py
from fastapi.testclient import TestClient from ...utils import needs_py39 @pytest.fixture(name="client") def get_client(): from docs_src.dependencies.tutorial008c_an_py39 import app client = TestClient(app) return client @needs_py39 def test_get_no_item(client: TestClient): response = client.get("/items/foo") assert response.status_code == 404, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Feb 24 23:06:37 UTC 2024 - 1.2K bytes - Viewed (0) -
tests/test_tutorial/test_request_files/test_tutorial002_py39.py
return app @pytest.fixture(name="client") def get_client(app: FastAPI): client = TestClient(app) return client file_required = { "detail": [ { "loc": ["body", "files"], "msg": "field required", "type": "value_error.missing", } ] } @needs_py39 def test_post_form_no_body(client: TestClient): response = client.post("/files/")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Apr 18 19:40:57 UTC 2024 - 9K bytes - Viewed (0) -
tests/test_tutorial/test_query_params_str_validations/test_tutorial014_an_py310.py
from fastapi.testclient import TestClient from ...utils import needs_py310 @pytest.fixture(name="client") def get_client(): from docs_src.query_params_str_validations.tutorial014_an_py310 import app client = TestClient(app) return client @needs_py310 def test_hidden_query(client: TestClient): response = client.get("/items?hidden_query=somevalue") assert response.status_code == 200, response.text
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jun 30 18:25:16 UTC 2023 - 3.1K bytes - Viewed (0)