- Sort Score
- Result 10 results
- Languages All
Results 521 - 530 of 1,127 for def2 (0.14 sec)
-
tests/test_tutorial/test_schema_extra_example/test_tutorial004_an.py
# Test required and embedded body parameters with no bodies sent def test_post_body_example(): response = client.put( "/items/5", json={ "name": "Foo", "description": "A very nice Item", "price": 35.4, "tax": 3.2, }, ) assert response.status_code == 200 def test_openapi_schema(): response = client.get("/openapi.json")
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Fri Jul 07 17:12:13 UTC 2023 - 6.9K bytes - Viewed (0) -
ci/official/utilities/convert_msys_paths_to_win_paths.py
This is necessary on Windows, because some applications do not understand/handle Linux-like paths MSYS uses, for example, Docker. """ import argparse import os def should_convert(var_name: str, blacklist: list[str] | None, whitelist_prefix: list[str] | None): """Check the variable name against white/black lists."""
Registered: Tue Nov 05 12:39:12 UTC 2024 - Last Modified: Wed Aug 07 23:01:25 UTC 2024 - 2.5K bytes - Viewed (0) -
docs_src/custom_response/tutorial007.py
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Mar 26 19:09:53 UTC 2020 - 277 bytes - Viewed (0) -
tests/test_tutorial/test_dataclasses/test_tutorial001.py
from docs_src.dataclasses.tutorial001 import app client = TestClient(app) def test_post_item(): response = client.post("/items/", json={"name": "Foo", "price": 3}) assert response.status_code == 200 assert response.json() == { "name": "Foo", "price": 3, "description": None, "tax": None, } def test_post_invalid_item():
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Thu Apr 18 19:40:57 UTC 2024 - 5.2K bytes - Viewed (0) -
docs_src/custom_response/tutorial008.py
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Mon Jul 19 19:14:58 UTC 2021 - 360 bytes - Viewed (0) -
docs_src/settings/app03/main.py
from functools import lru_cache from fastapi import Depends, FastAPI from . import config app = FastAPI() @lru_cache def get_settings(): return config.Settings() @app.get("/info") async def info(settings: config.Settings = Depends(get_settings)): return { "app_name": settings.app_name, "admin_email": settings.admin_email, "items_per_user": settings.items_per_user,
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Oct 24 20:26:06 UTC 2023 - 412 bytes - Viewed (0) -
docs_src/openapi_callbacks/tutorial001.py
invoices_callback_router = APIRouter() @invoices_callback_router.post( "{$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.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat May 14 11:59:59 UTC 2022 - 1.3K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/base/ToStringHelperTest.java
+ "field1=This is string., field2=[abc, def, ghi], field3={abc=1, def=2, ghi=3}}"; assertEquals(expected, toTest); } public void testToStringLenient_complexFields() { Map<String, Integer> map = ImmutableMap.<String, Integer>builder().put("abc", 1).put("def", 2).put("ghi", 3).build(); String toTest = MoreObjects.toStringHelper(new TestClass()) .add("field1", "This is string.")
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 09 21:19:18 UTC 2024 - 21.3K bytes - Viewed (0) -
docs_src/settings/app02_an/main.py
from functools import lru_cache from fastapi import Depends, FastAPI from typing_extensions import Annotated from .config import Settings app = FastAPI() @lru_cache def get_settings(): return Settings() @app.get("/info") async def info(settings: Annotated[Settings, Depends(get_settings)]): return { "app_name": settings.app_name, "admin_email": settings.admin_email,
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Oct 24 20:26:06 UTC 2023 - 456 bytes - Viewed (0) -
docs_src/settings/app03_an/main.py
from functools import lru_cache from typing import Annotated from fastapi import Depends, FastAPI from . import config app = FastAPI() @lru_cache def get_settings(): return config.Settings() @app.get("/info") async def info(settings: Annotated[config.Settings, Depends(get_settings)]): return { "app_name": settings.app_name, "admin_email": settings.admin_email,
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Oct 24 20:26:06 UTC 2023 - 451 bytes - Viewed (0)