You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 14, 2022. It is now read-only.
Repository navigation
This repository was archived by the owner on Sep 14, 2022. It is now read-only.
Why does mock mode require x-swagger-router-controller? This seems unintuitive - I haven't created any controller yet so why does it need a name?
IMO ideally mock mode would not mock routes with both x-swagger-router-controller and operationId - these are ones I've already coded, but should just mock the routes without these attributes.
This would allow me to incrementally design my API, with real code, without having to restart Swagger Node all the time based on whether I'm implementing an API or designing a new one.
Reacted by Olaf Geibig, Alexander Krylovsky, Igor Loskutov, Alexandre Paquette, praba-gopalan, eh, Ricardo Cardona Ramirez, Nick Budak, Danilo Spinelli, harold and 3 more
Activity
webron commentedon Jan 14, 2016
For future reference - https://github.com/apigee-127/swagger-tools/blob/master/docs/Middleware.md#how-to-use.
josephearl commentedon Sep 6, 2016
Why does mock mode require
x-swagger-router-controller? This seems unintuitive - I haven't created any controller yet so why does it need a name?IMO ideally mock mode would not mock routes with both
x-swagger-router-controllerandoperationId- these are ones I've already coded, but should just mock the routes without these attributes.This would allow me to incrementally design my API, with real code, without having to restart Swagger Node all the time based on whether I'm implementing an API or designing a new one.
xx7y7xx commentedon Oct 21, 2016
I think it is a document bug.
https://github.com/swagger-api/swagger-node/blob/master/docs/mock-mode.md#quick-example-mock-mode-in-action
x-swagger-router-controller: weatheris not include in the sample yaml config.[-]mock mode does not work[/-][+]mock mode does not work due to doc error[/+]fix mock mode example
fix mock mode example
fix mock mode example
fix mock mode example