Azure / openapi-diff

Command line tool to detect breaking changes between two openapi specifications
MIT License
253 stars 34 forks source link

Fix 'Missing required property: name' at x-ms-enum #302

Closed mikeharder closed 4 months ago

mikeharder commented 4 months ago

Depends on:

Notes by @konrad-jamrozik:

Relevant private chat about this PR is here

konrad-jamrozik commented 4 months ago

@mikeharder can you provide some context about the added .json files?

Specifically:

If you may, I would also appreciate some tip how did you record/obtain this data, so I can do the same in the future.

mikeharder commented 4 months ago

@mikeharder can you provide some context about the added .json files?

Specifically:

  • are all the added .json files a dependency of the added src/test/xmsEnumNameTest.ts or some of them are standalone, just as "FYI for the reader" ?
  • are all the added test files related to the bugfix in this PR, or go beyond that? If so, are they due to some recent prod PR failures (link?)

If you may, I would also appreciate some tip how did you record/obtain this data, so I can do the same in the future.

All the files added under not-match-oneof and x-ms-enum-name are full copies of the real spec from azure-rest-api-specs that exposed the bug. The examples are required to load the spec in autorest (spec points to examples). While this is a quick way to repro an issue, I'm starting to think the examples in our tests should be minimized repros rather than real-world specs. For testing real-world specs, we should test directly in azure-rest-api-specs.