Does validation by swagger-parser
actually work?
#284
Labels
pinned
Issues that will not be automatically closed
swagger-parser
actually work?
#284
Describe the bug
The README says:
I may be misunderstanding what this means, but it doesn't seem like it is true. I am able to provide an invalid spec and
swagger-jsdoc
does not complain.Looking at this code:
swagger-jsdoc/src/specification.js
Lines 100 to 104 in e1b8902
The
parse
method fromswagger-parser
is asynchronous, but this library is not handling it that way.To Reproduce
routes.js
(note the invalidxxxdescriptionxxx
property):generate.js
:generate.js
and paste output in https://editor.swagger.io/Expected behavior
swaggerJsdoc
should error or warn when it encounters invalid specThe text was updated successfully, but these errors were encountered: