Open PhilippeJousse opened 9 months ago
Hey @PhilippeJousse! 👋
I want to use prism mock with an order of request with specific response to follow.
This comes up from time to time and there's a roadmap item to +1 if you'd like, but we do not currently have plans to implement a persistence layer within Prism.
Hey, I misspoke about the user story. I'd like to publish a feature I've developed that allows you to provide a Gherkin file like the one in my first post that represents scenarios, i.e. a list of requests with their responses and then Prism will answer according to the scenario file. I will push a pull request in the coming weeks. I hope you will check it out with care. Thanks.
Ah, I see. Looking forward to seeing the PR :)
User Story Description
As a developer or tester,
I want to use prism mock with an order of request with specific response to follow.
so I can give a scenario file written with Gherkin syntax with each request which have Request path/Request verb/Response code/Response example/Response headers. Also I can choose to launch Prism with scenario mode ON or not with cli option
Example : 1st Request : GET on /users/10 -> Status 200 (OK)-> Give data 2nd Request : DELETE on /users/10 -> Status 201 (No content) 3rd Request : GET on /users/10 -> Status 404 (Not Found)
Example of Gherkin file :