OpenAPI: support optional attributes and Array<> syntax in inline sch…#228
OpenAPI: support optional attributes and Array<> syntax in inline sch…#228ayushman1210 wants to merge 3 commits intorage-rb:mainfrom
Conversation
|
Hi @rsamoilov please review this pr when you have some free time and let me know if anything else needed |
rsamoilov
left a comment
There was a problem hiding this comment.
Left one small comment. Otherwise, looks good 👍
rsamoilov
left a comment
There was a problem hiding this comment.
This looks good. The only thing is that this doesn't seem to support enums. For example, the [IN_PROGRESS, COMPLETED] expression creates an enum, but Array<IN_PROGRESS, COMPLETED> is not parsed correctly.
|
hi @rsamoilov i have updated the pr please review it thanks !! |
|
I can still see the error - for the Do you think it would be easier to preprocess YAML responses and just substitute |
Description
This PR addresses two limitations in the inline YAML schema parser used for @request and @response tags, as described in the issue
2.Array<> Syntax Support: Added support for the Array syntax inside inline schemas to provide a consistent alternative to the unary array [Type] syntax.
Changes
File --> lib/rage/openapi/parsers/yaml.rb
File --> spec/openapi/parsers/yaml_spec.rb
Verification
Fixes #227