Skip to content

Doesn't take pattern field into account #770

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 18, 2025
Merged

Doesn't take pattern field into account #770

merged 1 commit into from
Apr 18, 2025

Conversation

DrSatyr
Copy link
Collaborator

@DrSatyr DrSatyr commented Apr 18, 2025

Fixes #104

Fixes #104
@DrSatyr DrSatyr requested a review from Copilot April 18, 2025 09:20
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes #104 by adding support for comparing the "pattern" field in the OpenAPI schema diff.

  • Introduces a new ChangedPattern class to encapsulate pattern differences.
  • Extends the ChangedSchema model to incorporate pattern change detection.
  • Updates test cases to validate pattern unchanged, modified, removed, and added scenarios.

Reviewed Changes

Copilot reviewed 4 out of 6 changed files in this pull request and generated no comments.

File Description
core/src/test/java/org/openapitools/openapidiff/core/SchemaDiffTest.java Adds test cases for pattern change scenarios.
core/src/main/java/org/openapitools/openapidiff/core/model/schema/ChangedPattern.java Introduces a new class for representing pattern differences.
core/src/main/java/org/openapitools/openapidiff/core/model/ChangedSchema.java Integrates ChangedPattern into schema comparisons and updates equals/hashCode/toString.
core/src/main/java/org/openapitools/openapidiff/core/compare/schemadiffresult/SchemaDiffResult.java Applies pattern diff detection in the diff result construction.
Files not reviewed (2)
  • core/src/test/resources/schemaDiff/schema-pattern-diff-1.yaml: Language not supported
  • core/src/test/resources/schemaDiff/schema-pattern-diff-2.yaml: Language not supported

@DrSatyr DrSatyr merged commit 593e8a1 into master Apr 18, 2025
6 checks passed
@DrSatyr DrSatyr deleted the DrSatyr/issue104 branch April 18, 2025 09:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Doesn't take pattern field into account
1 participant