Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 587 for Name (0.14 sec)

  1. tests/test_response_by_alias.py

    @app.get("/no-alias/dict", response_model=ModelNoAlias)
    def no_alias_dict():
        return {"name": "Foo"}
    
    
    @app.get("/no-alias/model", response_model=ModelNoAlias)
    def no_alias_model():
        return ModelNoAlias(name="Foo")
    
    
    @app.get("/no-alias/list", response_model=List[ModelNoAlias])
    def no_alias_list():
        return [{"name": "Foo"}, {"name": "Bar"}]
    
    
    client = TestClient(app)
    
    
    def test_read_dict():
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Jul 07 17:12:13 GMT 2023
    - 11.1K bytes
    - Viewed (0)
  2. docs_src/python_types/tutorial010.py

    class Person:
        def __init__(self, name: str):
            self.name = name
    
    
    def get_person_name(one_person: Person):
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Jun 12 21:44:23 GMT 2020
    - 144 bytes
    - Viewed (0)
  3. tests/test_tutorial/test_schema_extra_example/test_tutorial005_an.py

                        },
                    },
                    "Item": {
                        "title": "Item",
                        "required": ["name", "price"],
                        "type": "object",
                        "properties": {
                            "name": {"title": "Name", "type": "string"},
                            "description": IsDict(
                                {
                                    "title": "Description",
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Aug 26 18:03:13 GMT 2023
    - 6.7K bytes
    - Viewed (0)
  4. tests/test_include_router_defaults_overrides.py

                        "parameters": [
                            {
                                "required": True,
                                "schema": {"title": "Level1", "type": "string"},
                                "name": "level1",
                                "in": "query",
                            }
                        ],
                        "responses": {
                            "200": {
    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)
  5. tests/test_tutorial/test_additional_status_codes/test_tutorial001_an_py310.py

    
    @needs_py310
    def test_create(client: TestClient):
        response = client.put("/items/red", json={"name": "Chillies"})
        assert response.status_code == 201, response.text
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 741 bytes
    - Viewed (0)
  6. tests/test_tutorial/test_additional_status_codes/test_tutorial001_an_py39.py

    
    @needs_py39
    def test_create(client: TestClient):
        response = client.put("/items/red", json={"name": "Chillies"})
        assert response.status_code == 201, response.text
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 737 bytes
    - Viewed (0)
  7. tests/test_tutorial/test_schema_extra_example/test_tutorial001_pv1.py

                            "name": {"type": "string", "title": "Name"},
                            "description": {"type": "string", "title": "Description"},
                            "price": {"type": "number", "title": "Price"},
                            "tax": {"type": "number", "title": "Tax"},
                        },
                        "type": "object",
                        "required": ["name", "price"],
                        "title": "Item",
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Jul 07 17:12:13 GMT 2023
    - 4.4K bytes
    - Viewed (0)
  8. tests/test_tutorial/test_body_updates/test_tutorial001_py39.py

    
    @pytest.fixture(name="client")
    def get_client():
        from docs_src.body_updates.tutorial001_py39 import app
    
        client = TestClient(app)
        return client
    
    
    @needs_py39
    def test_get(client: TestClient):
        response = client.get("/items/baz")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "name": "Baz",
            "description": None,
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Thu Sep 28 04:14:40 GMT 2023
    - 11.8K bytes
    - Viewed (0)
  9. tests/test_union_body.py

                                "name": {
                                    "title": "Name",
                                    "anyOf": [{"type": "string"}, {"type": "null"}],
                                }
                            }
                        )
                        | IsDict(
                            # TODO: remove when deprecating Pydantic v1
                            {"name": {"title": "Name", "type": "string"}}
                        ),
    Python
    - Registered: Sun Apr 28 07:19:10 GMT 2024
    - Last Modified: Fri Jul 07 17:12:13 GMT 2023
    - 4.6K bytes
    - Viewed (0)
  10. tests/test_request_body_parameters_media_type.py

                        },
                    },
                    "Product": {
                        "title": "Product",
                        "required": ["name", "price"],
                        "type": "object",
                        "properties": {
                            "name": {"title": "Name", "type": "string"},
                            "price": {"title": "Price", "type": "number"},
                        },
                    },
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Jul 07 17:12:13 GMT 2023
    - 6.4K bytes
    - Viewed (0)
Back to top