- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 16 for Boetes (0.34 sec)
-
tests/test_custom_route_class.py
assert response.json() == expected_response def test_route_classes(): routes = {} for r in app.router.routes: assert isinstance(r, Route) routes[r.path] = r assert getattr(routes["/a/"], "x_type") == "A" # noqa: B009 assert getattr(routes["/a/b/"], "x_type") == "B" # noqa: B009 assert getattr(routes["/a/b/c/"], "x_type") == "C" # noqa: B009 def test_openapi_schema():
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jun 30 18:25:16 GMT 2023 - 3.1K bytes - Viewed (0) -
tests/test_additional_responses_custom_model_in_callback.py
@callback_router.get( "{$callback_url}/callback/", responses={400: {"model": CustomModel}} ) def callback_route(): pass # pragma: no cover @app.post("/", callbacks=callback_router.routes) def main_route(callback_url: HttpUrl): pass # pragma: no cover client = TestClient(app) def test_openapi_schema(): response = client.get("/openapi.json")
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jul 07 17:12:13 GMT 2023 - 5.8K bytes - Viewed (0) -
tests/test_include_router_defaults_overrides.py
callbacks=callback_router4.routes, deprecated=True, ) router4_default = APIRouter() @app.get( "/override1", tags=["path1a", "path1b"], responses={ 401: {"description": "Client error level 1"}, 501: {"description": "Server error level 1"}, }, deprecated=True, callbacks=callback_router1.routes, dependencies=[Depends(dep1)],
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jun 30 18:25:16 GMT 2023 - 358.6K bytes - Viewed (0) -
docs_src/openapi_callbacks/tutorial001.py
"{$callback_url}/invoices/{$request.body.id}", response_model=InvoiceEventReceived ) def invoice_notification(body: InvoiceEvent): pass @app.post("/invoices/", callbacks=invoices_callback_router.routes) def create_invoice(invoice: Invoice, callback_url: Union[HttpUrl, None] = None): """ Create an invoice. This will (let's imagine) let the API user (some external developer) create an invoice.
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sat May 14 11:59:59 GMT 2022 - 1.3K bytes - Viewed (0) -
tests/test_tutorial/test_openapi_webhooks/test_tutorial001.py
response = client.get("/users/") assert response.status_code == 200, response.text assert response.json() == ["Rick", "Morty"] def test_dummy_webhook(): # Just for coverage app.webhooks.routes[0].endpoint({}) def test_openapi_schema(): response = client.get("/openapi.json") assert response.status_code == 200, response.text assert response.json() == { "openapi": "3.1.0",
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Fri Oct 20 09:00:44 GMT 2023 - 4.4K bytes - Viewed (2) -
fastapi/openapi/utils.py
return path, security_schemes, definitions def get_fields_from_routes( routes: Sequence[BaseRoute], ) -> List[ModelField]: body_fields_from_routes: List[ModelField] = [] responses_from_routes: List[ModelField] = [] request_fields_from_routes: List[ModelField] = [] callback_flat_models: List[ModelField] = [] for route in routes: if getattr(route, "include_in_schema", None) and isinstance(
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Thu Apr 18 19:40:57 GMT 2024 - 21.8K bytes - Viewed (0) -
tests/test_tutorial/test_async_sql_databases/test_tutorial001.py
} }, } }, "summary": "Read Notes", "operationId": "read_notes_notes__get", }, "post": { "responses": { "200": {
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Wed Oct 18 12:36:40 GMT 2023 - 6K bytes - Viewed (0) -
tests/test_extra_routes.py
Sebastián RamÃrez <******@****.***> 1688749933 +0200
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jul 07 17:12:13 GMT 2023 - 13.7K bytes - Viewed (0) -
docs_src/path_operation_advanced_configuration/tutorial002.py
def use_route_names_as_operation_ids(app: FastAPI) -> None: """ Simplify operation IDs so that generated API clients have simpler function names. Should be called only after all routes have been added. """ for route in app.routes: if isinstance(route, APIRoute): route.operation_id = route.name # in this case, 'read_items'
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Thu Mar 26 19:09:53 GMT 2020 - 572 bytes - Viewed (0) -
tests/test_sub_callbacks.py
def event_callback(event: Event): pass # pragma: nocover subrouter = APIRouter() @subrouter.post("/invoices/", callbacks=invoices_callback_router.routes) def create_invoice(invoice: Invoice, callback_url: Optional[HttpUrl] = None): """ Create an invoice. This will (let's imagine) let the API user (some external developer) create an invoice.
Python - Registered: Sun Apr 28 07:19:10 GMT 2024 - Last Modified: Fri Jul 07 17:12:13 GMT 2023 - 13.8K bytes - Viewed (0)