You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Drop the expected-path arguments of the parser and dynamic model tests - #7272
Auto incremental reviews are disabled on this repository.
Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.
You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.
Use the checkbox below for a quick retry:
Trigger review
No actionable comments were generated in the recent review.
Walkthrough
This change updates test assertions and reference manifests across dynamic-model, CLI, and parser tests. It replaces many explicit expected-file comparisons with named or suffix-based snapshots, revises fixture paths, and adjusts fixture aliases. The described test inputs and generation calls remain in place.
Dynamic-model tests replace many expected-file paths with named or inline snapshots. The reference manifest points to renamed and reorganized fixtures.
Main and shared parser output checks tests/main/test_main_json.py, tests/main/test_main_json.refs, tests/main/test_main_yaml.py, tests/main/test_main_yaml.refs, tests/generated_import_closure_allowlist.py, tests/parser/test_backend_capabilities.py, tests/parser/test_backend_capabilities.refs, tests/parser/test_builtin_formatter_contract.py, tests/parser/test_builtin_formatter_contract.refs
JSON and YAML tests remove file-content callbacks and update fixture paths. Backend and formatter tests use shared output assertions, and related parser fixture references are updated.
GraphQL, JSON Schema, and XML Schema snapshots tests/parser/test_graphql.py, tests/parser/test_graphql.refs, tests/parser/test_jsonschema.py, tests/parser/test_jsonschema.refs, tests/parser/test_xmlschema.py, tests/parser/test_xmlschema.refs
Parser tests replace fixed expected-file comparisons with suffix-based or named snapshots. Their reference manifests point to renamed or reorganized fixtures.
OpenAPI parser and scope snapshots tests/parser/test_openapi.py, tests/parser/test_openapi.refs, tests/parser/test_openapi_scope.py, tests/parser/test_openapi_scope.refs
OpenAPI parser and scope tests replace many expected-file comparisons with suffix, named-snapshot, and directory-content checks. The reference manifests point to parser-local fixtures and updated aliases.
This change renames test fixtures and simplifies test assertions with no production code changes. No merge-blocking risk was identified, though the tests were not run in this review.
Pre-merge checks: 4
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title "Drop the expected-path arguments of the parser and dynamic model tests" matches the main change. The raw summary shows that the parser and dynamic-model tests remove expected-file path argu…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title "Drop the expected-path arguments of the parser and dynamic model tests" matches the main change. The raw summary shows that the parser and dynamic-model tests remove expected-file path arguments from calls such as assert_output and assert_dynamic_models, and switch to suffix-based or named snapshot assertions. The title is specific and the scope matches the changed test files. The PR objectives describe the same change.
Finishing Touches
Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Reviewing files that changed from the base of the PR and between ff6a249 and 8a3ce6f.
Files ignored due to path filters: 58
docs/data/migration/unreleased/uuid-version-formats.toml is excluded by none and included by none
tests/data/expected/dynamic_models/circular_reference.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/allof_inheritance.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/allow_leading_underscore_class_name.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/build_module_edges_ignores_unresolvable_relative_imports.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/cache_distinguishes_schema_order[cache_defs_model_order-defs].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/cache_distinguishes_schema_order[cache_field_order-field].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/cache_distinguishes_schema_order[cache_nested_field_order-nested].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/cache_distinguishes_schema_order[cache_openapi_components_order-openapi].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/cache_hits_do_not_reorder_fifo_eviction.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/circular_reference.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/enum_model.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/force_optional_discriminator_literals.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/generated_code_matches_expected.validated.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/generated_root_model_aliases[aliases-ModuleSplitMode.Single-None-0].runtime.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/generated_root_model_aliases[aliases-None-None-0].runtime.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/imported_model_classes_are_not_returned.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/leading_underscore_class_name_default_unchanged.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/module_name_of_importable_module[importable].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/module_name_of_importable_module[missing-package].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/multi_module_output.model_order.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/multi_module_output.validated.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/multi_module_relative_parent_import.relative_parent_import.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/multi_module_relative_parent_import.relative_parent_import_payload.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/multi_module_restores_preexisting_modules_after_execution_failure.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/multiple_aliases_required_field.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/nested_models.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/numeric_constraints.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/openapi_auto_detection.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/optional_literal_discriminator_tags.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/ordinary_type_alias_extraction_is_unchanged.type_alias.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/private_root_model_aliases[False].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/private_root_model_aliases[True].txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/root_model_alias_assignments_ignore_nested_and_attribute_targets[False].runtime.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/root_model_alias_assignments_ignore_nested_and_attribute_targets[True].runtime.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/main/dynamic_models/simple_model.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/simple_model.optional.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/main/dynamic_models/string_constraints.json is excluded by !tests/data/**/*.json and included by none
tests/data/expected/parser/backend_capabilities/output_owned_parser_capabilities.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/parser/builtin_formatter_contract/generated_formatter_matches_full_formatter_corpus.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/parser/builtin_formatter_contract/generated_formatter_parser_config_contract.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/parser/jsonschema/builtin_formatter_falls_back_for_custom_class_name_generator.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/builtin_formatter_falls_back_for_custom_resolve_reference_action.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/generated_formatter_mode_only_enabled_for_builtin.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/parse_nested_array.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/schema_runtime_validation_copy_replans_unique_items_paths.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/schema_validator_adds_all_of_missing_required_field.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/schema_validator_unique_items_array_capability_branches.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/schema_validator_unique_items_branch_coverage.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/schema_validator_unique_items_executable_paths_cover_all_data_type_branches.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/schema_validator_unique_items_paths_cover_composed_input_shapes.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/traverse_schema_objects_falls_back_for_parser_subclass_children.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/traverse_schema_objects_handles_conditional_schemas_without_child_fields.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/traverse_schema_objects_keeps_explicit_empty_child_fields_on_regular_path.snapshot is excluded by none and included by none
tests/data/expected/parser/jsonschema/traverse_schema_objects_preserves_builtin_callback_order.snapshot is excluded by none and included by none
tests/data/expected/parser/openapi_scope/api_empty_inventory[False-AllExportsScope.Children-False].state.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/parser/openapi_scope/api_empty_inventory[True-AllExportsScope.Children-False].existing_output.txt is excluded by !tests/data/**/*.txt and included by none
tests/data/expected/parser/openapi_scope/api_empty_inventory[True-AllExportsScope.Children-False].state.txt is excluded by !tests/data/**/*.txt and included by none
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.
⚠️53 benchmarks with a significant change ran on different hardware
Their base and head results were measured on machines with a different CPU, core count or memory, so the changes might not come from the code. Run base and head on the same runner type.
This PR is now available in the latest release. See the release notes for details.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary by CodeRabbit