- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 20 for caisses (0.04 sec)
-
tests/test_inherited_custom_class.py
def serialize_a_uuid(self, v): return str(v) @app.get("/get_custom_class") def return_some_user(): # Test that the fix also works for custom pydantic classes return SomeCustomClass(a_uuid=MyUuid("b8799909-f914-42de-91bc-95c819218d01")) client = TestClient(app) with client: response_simple = client.get("/fast_uuid")
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 12:54:56 UTC 2025 - 1.8K bytes - Viewed (0) -
docs/en/docs/how-to/graphql.md
/// tip If you need GraphQL, I still would recommend you check out <a href="https://strawberry.rocks/" class="external-link" target="_blank">Strawberry</a>, as it's based on type annotations instead of custom classes and types. /// ## Learn More { #learn-more } You can learn more about **GraphQL** in the <a href="https://graphql.org/" class="external-link" target="_blank">official GraphQL documentation</a>.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 3.4K bytes - Viewed (0) -
tests/test_pydantic_v1_error.py
app = FastAPI() with pytest.raises(PydanticV1NotSupportedError): @app.post("/param") def endpoint(data: ParamModelV1): # pragma: no cover return data def test_raises_pydantic_v1_model_in_return_type() -> None: class ReturnModelV1(BaseModel): name: str app = FastAPI() with pytest.raises(PydanticV1NotSupportedError): @app.get("/return")Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 12:54:56 UTC 2025 - 2.3K bytes - Viewed (0) -
tests/test_jsonable_encoder.py
name: str data = ModelV1(name="test") with pytest.raises(PydanticV1NotSupportedError): jsonable_encoder(data) def test_encode_model_with_config(): model = ModelWithConfig(role=RoleEnum.admin) assert jsonable_encoder(model) == {"role": "admin"} def test_encode_model_with_alias_raises(): with pytest.raises(ValidationError): ModelWithAlias(foo="Bar")Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 12:54:56 UTC 2025 - 9.2K bytes - Viewed (0) -
tests/test_tutorial/test_python_types/test_tutorial003.py
import pytest from docs_src.python_types.tutorial003_py39 import get_name_with_age def test_get_name_with_age_pass_int(): with pytest.raises(TypeError): get_name_with_age("John", 30) def test_get_name_with_age_pass_str():
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 308 bytes - Viewed (0) -
tests/test_response_model_as_return_annotation.py
def test_response_model_no_annotation_return_invalid_dict(): with pytest.raises(ResponseValidationError) as excinfo: client.get("/response_model-no_annotation-return_invalid_dict") assert "missing" in str(excinfo.value) def test_response_model_no_annotation_return_invalid_model(): with pytest.raises(ResponseValidationError) as excinfo:
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 12:54:56 UTC 2025 - 47.7K bytes - Viewed (0) -
tests/test_tutorial/test_python_types/test_tutorial009c.py
return mod def test_say_hi(module: ModuleType): with patch("builtins.print") as mock_print: module.say_hi("FastAPI") mock_print.assert_called_once_with("Hey FastAPI!") with pytest.raises( TypeError, match=re.escape("say_hi() missing 1 required positional argument: 'name'"), ):
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 777 bytes - Viewed (0) -
tests/test_tutorial/test_settings/test_app01.py
monkeypatch.delenv("ADMIN_EMAIL", raising=False) if mod_name in sys.modules: del sys.modules[mod_name] # pragma: no cover with pytest.raises(ValidationError) as exc_info: importlib.import_module(mod_name) assert exc_info.value.errors() == [ { "loc": ("admin_email",), "msg": "Field required",
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 2.2K bytes - Viewed (0) -
scripts/translate.py
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 19:05:53 UTC 2025 - 34.1K bytes - Viewed (0) -
fastapi/_compat/v2.py
by_alias: bool = True, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, ) -> Any: # What calls this code passes a value that already called # self._type_adapter.validate_python(value) return self._type_adapter.dump_python( value, mode=mode, include=include,Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 12:54:56 UTC 2025 - 19.1K bytes - Viewed (0)