fastapi/tests
majiayu000 b8a617d62f Update ValidationError schema for Pydantic V2 compatibility
Add input, ctx, and url fields to the ValidationError OpenAPI definition
to accurately reflect the actual error structure returned by Pydantic V2.

Pydantic V2 validation errors include additional fields:
- input: The value that failed validation
- ctx: Additional context about the error (optional)
- url: Documentation URL for the error type (optional)

Fixes #10787
2025-12-14 17:02:12 +08:00
..
test_filter_pydantic_sub_model Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_modules_same_name_body Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_pydantic_v1_v2_multifile Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_request_params 🐛 Fix parameter aliases (#14371) 2025-12-12 15:56:57 +01:00
test_tutorial Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_validate_response_recursive Simplify tests for `validate_response_recursive` (#13507) 2025-06-17 12:24:10 +02:00
__init__.py Add first tests, for path and query 2018-12-08 11:56:07 +04:00
forward_reference_type.py Add support for wrapped functions (e.g. `@functools.wraps()`) used with forward references (#5077) 2025-12-02 18:23:14 +01:00
main.py Add OpenAPI `external_docs` parameter to `FastAPI` (#13713) 2025-09-20 19:11:46 +02:00
test_additional_properties.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_additional_properties_bool.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_additional_response_extra.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_additional_responses_bad.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_additional_responses_custom_model_in_callback.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_additional_responses_custom_validationerror.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_additional_responses_default_validationerror.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_additional_responses_response_class.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_additional_responses_router.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_allow_inf_nan_in_enforcing.py 🐛 Fix `allow_inf_nan` option for Param and Body classes (#11867) 2024-08-24 14:27:37 -05:00
test_ambiguous_params.py Add support for multiple Annotated annotations, e.g. `Annotated[str, Field(), Query()]` (#10773) 2023-12-12 00:22:47 +00:00
test_annotated.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_application.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_arbitrary_types.py 🐛 Fix handling arbitrary types when using `arbitrary_types_allowed=True` (#14482) 2025-12-10 11:36:29 +01:00
test_callable_endpoint.py 📝 Use Optional in docs (#1644) 2020-06-28 20:13:30 +02:00
test_compat.py 🐛 Fix optional sequence handling with new union syntax from Python 3.10 (#14430) 2025-12-02 16:59:38 +00:00
test_compat_params_v1.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_computed_fields.py 🐛 Fix OpenAPI schema support for computed fields when using `separate_input_output_schemas=False` (#13207) 2025-12-02 09:22:08 +00:00
test_custom_middleware_exception.py Allow custom middlewares to raise `HTTPException`s and propagate them (#2036) 2022-08-25 23:44:40 +02:00
test_custom_route_class.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_custom_schema_fields.py Allow array values for OpenAPI schema `type` field (#13639) 2025-09-20 17:47:24 +00:00
test_custom_swagger_ui_redirect.py Improve test debugging (#1222) 2020-04-08 06:37:38 +02:00
test_datastructures.py Add reference (code API) docs with PEP 727, add subclass with custom docstrings for `BackgroundTasks`, refactor docs structure (#10392) 2023-10-18 16:36:40 +04:00
test_datetime_custom_encoder.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_default_response_class.py Re-export utils from Starlette (#1064) 2020-03-01 21:49:20 +01:00
test_default_response_class_router.py Re-export utils from Starlette (#1064) 2020-03-01 21:49:20 +01:00
test_dependency_after_yield_raise.py 🐛 Fix support for `StreamingResponse`s with dependencies with `yield` or `UploadFile`s, close after the response is done (#14099) 2025-09-29 05:29:38 +02:00
test_dependency_after_yield_streaming.py 🐛 Fix support for `StreamingResponse`s with dependencies with `yield` or `UploadFile`s, close after the response is done (#14099) 2025-09-29 05:29:38 +02:00
test_dependency_after_yield_websockets.py 🐛 Fix support for `StreamingResponse`s with dependencies with `yield` or `UploadFile`s, close after the response is done (#14099) 2025-09-29 05:29:38 +02:00
test_dependency_cache.py 🐛 Fix cached dependencies when using a dependency in `Security()` and other places (e.g. `Depends()`) with different OAuth2 scopes (#2945) 2022-08-23 13:30:24 +00:00
test_dependency_class.py 🐛 Fix using class (not instance) dependency that has `__call__` method (#14458) 2025-12-05 21:21:05 +00:00
test_dependency_contextmanager.py 🐛 Fix support for `StreamingResponse`s with dependencies with `yield` or `UploadFile`s, close after the response is done (#14099) 2025-09-29 05:29:38 +02:00
test_dependency_contextvars.py Update internal `AsyncExitStack` to fix context for dependencies with `yield` (#4575) 2022-02-17 13:40:12 +01:00
test_dependency_duplicates.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_dependency_overrides.py Add support for Pydantic's 2.7 new deprecated Field parameter, remove URL from validation errors response (#11461) 2024-04-18 14:40:57 -05:00
test_dependency_paramless.py ♻️ Reduce internal cyclic recursion in dependencies, from 2 functions calling each other to 1 calling itself (#14256) 2025-10-30 20:35:04 +01:00
test_dependency_partial.py Allow using dependables with `functools.partial()` (#9753) 2025-12-02 20:58:30 +00:00
test_dependency_security_overrides.py 🐛 Fix testing security scopes when using dependency overrides (#1549) 2020-06-14 17:54:46 +02:00
test_dependency_wrapped.py 🐛 Fix support for functools wraps and partial combined, for async and regular functions and classes in path operations and dependencies (#14448) 2025-12-04 08:29:28 +01:00
test_dependency_yield_except_httpexception.py 🐛 Fix support for `StreamingResponse`s with dependencies with `yield` or `UploadFile`s, close after the response is done (#14099) 2025-09-29 05:29:38 +02:00
test_dependency_yield_scope.py 🐛 Fix `Depends(func, scope='function')` for top level (parameterless) dependencies (#14301) 2025-11-08 22:43:30 +01:00
test_dependency_yield_scope_websockets.py Add support for dependencies with scopes, support `scope="request"` for dependencies with `yield` that exit before the response is sent (#14262) 2025-11-03 11:12:49 +01:00
test_depends_hashable.py ♻️ Make the result of `Depends()` and `Security()` hashable, as a workaround for other tools interacting with these internal parts (#14372) 2025-11-19 17:50:18 +01:00
test_deprecated_openapi_prefix.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_duplicate_models_openapi.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_empty_router.py ⬆️ Upgrade and fully migrate to Ruff, remove isort, includes a couple of tweaks suggested by the new version of Ruff (#9660) 2023-06-12 00:37:34 +02:00
test_enforce_once_required_parameter.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_exception_handlers.py 🐛 Preserve traceback when exception is raised in sync dependency with `yield` (#5823) 2024-12-03 23:37:12 +01:00
test_extra_routes.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_fastapi_cli.py 🐛 Fix Windows UnicodeEncodeError in CLI test (#14295) 2025-12-02 04:02:38 +00:00
test_file_and_form_order_issue_9116.py 🐛 Fix validation error when `File` is declared after `Form` parameter (#11194) 2025-09-20 21:55:59 +02:00
test_filter_pydantic_sub_model_pv2.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_form_default.py 🐛 Fix support for form values with empty strings interpreted as missing (`None` if that's the default), for compatibility with HTML forms (#13537) 2025-12-02 05:39:55 +01:00
test_forms_from_non_typing_sequences.py Add support for not needing `...` as default value in required Query(), Path(), Header(), etc. (#4906) 2022-05-13 18:38:22 -05:00
test_forms_single_model.py 🐛 Fix parsing extra `Form` parameter list (#14303) 2025-12-02 05:49:32 +01:00
test_forms_single_param.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_generate_unique_id_function.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_generic_parameterless_depends.py ⬆ Bump ruff to 0.9.4 (#13299) 2025-03-06 13:18:57 +01:00
test_get_model_definitions_formfeed_escape.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_get_request_body.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_http_connection_injection.py Add support for injecting HTTPConnection (#1827) 2020-08-09 15:56:41 +02:00
test_include_route.py Improve test debugging (#1222) 2020-04-08 06:37:38 +02:00
test_include_router_defaults_overrides.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_infer_param_optionality.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_inherited_custom_class.py ⬆️ Upgrade version of Ruff and reformat (#12032) 2024-08-16 23:13:50 -05:00
test_invalid_path_param.py 🐛 Fix path and query parameters receiving dict as valid (#287) 2019-06-03 21:59:40 +04:00
test_invalid_sequence_param.py Add support for not needing `...` as default value in required Query(), Path(), Header(), etc. (#4906) 2022-05-13 18:38:22 -05:00
test_jsonable_encoder.py 🐛 Fix `TypeError` when encoding a decimal with a `NaN` or `Infinity` value (#12935) 2025-12-02 04:31:59 +01:00
test_local_docs.py Improve type annotations, add support for mypy --strict, internally and for external packages (#2547) 2020-12-20 19:50:00 +01:00
test_multi_body_errors.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_multi_query_errors.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_multipart_installation.py ♻️ Update logic to import and check `python-multipart` for compatibility with newer version (#12627) 2024-10-27 21:46:26 +00:00
test_no_schema_split.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_no_swagger_ui_redirect.py Improve test debugging (#1222) 2020-04-08 06:37:38 +02:00
test_openapi_examples.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_openapi_model_description_trim_on_formfeed.py 🐛 Fix truncating the model's description with form feed (`\f`) character for Pydantic V2 (#13698) 2025-06-17 09:46:27 +02:00
test_openapi_query_parameter_extension.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_openapi_route_extensions.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_openapi_schema_type.py Allow array values for OpenAPI schema `type` field (#13639) 2025-09-20 17:47:24 +00:00
test_openapi_separate_input_output_schemas.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_openapi_servers.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_operations_signatures.py Add include, exclude, and by_alias to path operation methods (#264) 2019-05-27 16:08:13 +04:00
test_optional_file_list.py 🐛 Fix optional sequence handling in `serialize sequence value` with Pydantic V2 (#14297) 2025-12-02 08:10:27 +01:00
test_orjson_response_class.py Update `ORJSONResponse` to support non `str` keys and serializing Numpy arrays (#3892) 2022-09-02 10:17:31 +00:00
test_param_class.py Add support for not needing `...` as default value in required Query(), Path(), Header(), etc. (#4906) 2022-05-13 18:38:22 -05:00
test_param_in_path_and_dependency.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_param_include_in_schema.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_params_repr.py ♻️ Refactor internals of dependencies, simplify using dataclasses (#14254) 2025-10-30 05:51:50 +01:00
test_path.py Add support for Pydantic's 2.7 new deprecated Field parameter, remove URL from validation errors response (#11461) 2024-04-18 14:40:57 -05:00
test_put_no_body.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_pydantic_v1_v2_01.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_pydantic_v1_v2_list.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_pydantic_v1_v2_mixed.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_pydantic_v1_v2_noneable.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_pydanticv2_dataclasses_uuid_stringified_annotations.py Add test for Pydantic v2, dataclasses, UUID, and `__annotations__` (#14477) 2025-12-09 12:12:24 +01:00
test_query.py 🐛 Fix support for query parameters with list types, handle JSON encoding Pydantic `UndefinedType` (#9929) 2024-04-18 16:56:59 -05:00
test_query_cookie_header_model_extra_params.py 🐛 Fix parsing extra non-body parameter list (#14356) 2025-12-02 05:57:19 +01:00
test_read_with_orm_mode.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_regex_deprecated_body.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_regex_deprecated_params.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_repeated_cookie_headers.py 🐛 Fix duplicated headers set by indirect dependencies (#1386) 2020-06-13 14:44:51 +02:00
test_repeated_dependency_schema.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_repeated_parameter_alias.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_reponse_set_reponse_code_empty.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_request_body_parameters_media_type.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_request_param_model_by_alias.py 🐛 Fix Query\Header\Cookie parameter model alias (#14360) 2025-12-02 07:24:09 +00:00
test_required_noneable.py Add tests for required nonable parameters and body fields (#4907) 2022-05-14 19:08:31 +00:00
test_response_by_alias.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_response_change_status_code.py Improve test debugging (#1222) 2020-04-08 06:37:38 +02:00
test_response_class_no_mediatype.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_response_code_no_body.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_response_model_as_return_annotation.py 🐛 Fix internal Pydantic v1 compatibility (warnings) for Python 3.14 and Pydantic 2.12.1 (#14186) 2025-10-20 13:26:49 +02:00
test_response_model_data_filter.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_response_model_data_filter_no_inheritance.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_response_model_default_factory.py ️ Fix `default_factory` for response model field with Pydantic V1 (#9704) 2025-09-20 20:51:40 +02:00
test_response_model_include_exclude.py 🔧 Configure strict pytest options and update/refactor tests (#2790) 2021-07-19 21:14:58 +02:00
test_response_model_invalid.py 🐛 Admit valid types for Pydantic fields as responses models (#1017) 2020-02-29 14:04:35 +01:00
test_response_model_sub_types.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_return_none_stringified_annotations.py Allow `None` as return type for bodiless responses (#9425) 2025-09-20 18:44:43 +00:00
test_route_scope.py 🐛 Fix support for `StreamingResponse`s with dependencies with `yield` or `UploadFile`s, close after the response is done (#14099) 2025-09-29 05:29:38 +02:00
test_router_events.py 🐛 Ensure that `app.include_router` merges nested lifespans (#9630) 2024-08-24 14:09:52 -05:00
test_router_prefix_with_template.py Improve test debugging (#1222) 2020-04-08 06:37:38 +02:00
test_router_redirect_slashes.py Add allow disabling `redirect_slashes` at the FastAPI app level (#3432) 2023-06-22 10:37:50 +00:00
test_schema_compat_pydantic_v2.py 🐛 Avoid accessing non-existing "$ref" key for Pydantic v2 compat remapping (#14361) 2025-12-02 05:04:13 +01:00
test_schema_extra_examples.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_schema_ref_pydantic_v2.py 🐛 Fix handling of JSON Schema attributes named "$ref" (#14349) 2025-11-13 14:59:07 +01:00
test_security_api_key_cookie.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_api_key_cookie_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_api_key_cookie_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_api_key_header.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_api_key_header_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_api_key_header_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_api_key_query.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_api_key_query_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_api_key_query_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_http_base.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_base_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_base_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_http_basic_optional.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_basic_realm.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_basic_realm_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_bearer.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_bearer_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_bearer_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_http_digest.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_digest_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_http_digest_optional.py 🐛 Ensure that `HTTPDigest` only raises an exception when `auto_error is True` (#2939) 2025-02-27 13:29:20 +01:00
test_security_oauth2.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_security_oauth2_authorization_code_bearer.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_oauth2_authorization_code_bearer_description.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_oauth2_authorization_code_bearer_scopes_openapi.py 🐛 Fix OAuth2 scopes in OpenAPI in extra corner cases, parent dependency with scopes, sub-dependency security scheme without scopes (#14459) 2025-12-04 23:22:01 +01:00
test_security_oauth2_authorization_code_bearer_scopes_openapi_simple.py 🐛 Fix OAuth2 scopes in OpenAPI in extra corner cases, parent dependency with scopes, sub-dependency security scheme without scopes (#14459) 2025-12-04 23:22:01 +01:00
test_security_oauth2_optional.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_security_oauth2_optional_description.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_security_oauth2_password_bearer_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_oauth2_password_bearer_optional_description.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_openid_connect.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_openid_connect_description.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_security_openid_connect_optional.py Add support for OpenAPI 3.1.0 (#9770) 2023-06-30 20:25:16 +02:00
test_security_scopes.py 🐛 Cache dependencies that don't use scopes and don't have sub-dependencies with scopes (#14419) 2025-11-30 15:45:49 +01:00
test_security_scopes_dont_propagate.py 🐛 Fix hierarchical security scope propagation (#5624) 2025-11-30 12:57:01 +01:00
test_security_scopes_sub_dependency.py 🐛 Cache dependencies that don't use scopes and don't have sub-dependencies with scopes (#14419) 2025-11-30 15:45:49 +01:00
test_serialize_response.py 🎨 Add typing.Optional to variables that accept None as value (#1731) 2020-08-03 14:29:07 +02:00
test_serialize_response_dataclass.py 🐛 Fix `jsonable_encoder` for dataclasses with pydantic-compatible fields (#3607) 2022-08-26 15:56:47 +02:00
test_serialize_response_model.py Add support for not needing `...` as default value in required Query(), Path(), Header(), etc. (#4906) 2022-05-13 18:38:22 -05:00
test_skip_defaults.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_starlette_exception.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_starlette_urlconvertors.py ⬆ Bump Starlette to version `0.22.0` to fix bad encoding for query parameters in `TestClient` (#5659) 2022-11-27 15:46:06 +01:00
test_stringified_annotation_dependency.py 🐛 Fix support for `if TYPE_CHECKING`, non-evaluated stringified annotations (#14485) 2025-12-10 13:06:05 +01:00
test_stringified_annotations_simple.py 🐛 Fix evaluating stringified annotations in Python 3.10 (#11355) 2025-12-04 09:18:32 +01:00
test_sub_callbacks.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_swagger_ui_init_oauth.py 🔧 Add Flake8 linting (#1774) 2020-08-09 12:54:05 +02:00
test_top_level_security_scheme_in_openapi.py 🐛 Use `401` status code in security classes when credentials are missing (#13786) 2025-11-24 20:03:06 +01:00
test_tuples.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_typing_python39.py 📝 Update all docs to use `Annotated` as the main recommendation, with new examples and tests (#9268) 2023-03-18 13:29:59 +01:00
test_union_body.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_union_body_discriminator.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_union_body_discriminator_annotated.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_union_forms.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_union_inherited_body.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_validate_response.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_validate_response_dataclass.py Add support for Pydantic v2 (#9816) 2023-07-07 19:12:13 +02:00
test_validation_error_context.py 🚸 Improve tracebacks by adding endpoint metadata (#14306) 2025-12-06 12:21:57 +00:00
test_webhooks_security.py Update ValidationError schema for Pydantic V2 compatibility 2025-12-14 17:02:12 +08:00
test_wrapped_method_forward_reference.py Add support for wrapped functions (e.g. `@functools.wraps()`) used with forward references (#5077) 2025-12-02 18:23:14 +01:00
test_ws_dependencies.py Add support for `dependencies` in WebSocket routes (#4534) 2023-06-11 20:35:39 +00:00
test_ws_router.py Add exception handler for `WebSocketRequestValidationError` (which also allows to override it) (#6030) 2023-06-11 21:08:14 +02:00
utils.py Add support for `from pydantic.v1 import BaseModel`, mixed Pydantic v1 and v2 models in the same app (#14168) 2025-10-11 18:45:54 +02:00