xuorig / anicca

Get a diff between two OpenAPI descriptions.
MIT License
25 stars 0 forks source link

`paths.changed.{path}` does not need the `{ operations_added, operations_changed, operations_removed }` layer #11

Open gr2m opened 2 years ago

gr2m commented 2 years ago

Example:

image

E.g. instead of

paths.changed.paths["/app"].operations_changed.get

you could just do

paths.change.paths["/app"].get

The operations_changed is implied by the changed

gr2m commented 2 years ago

Oh I think I get it, there might be a case when an operation is removed in a path, in which case we would get

paths.changed.paths["/app"].operations_removed.get

but I don't think that this is currently implemented that way?

gr2m commented 2 years ago

I think it would be easier to grasp if you all three of paths.{added,changed,removed} had the same format as paths in the source/target OpenAPI files (paths[path][method]), that way it's clear to see which are the operations that are added, which have been changed, which have been removed.