Mock API, what is the best practices to mock swagger openapi

mcmatak
Member | 504
+
0
-

Can you suggest the best practices when i want to mock api for testing purpouses?

I have api based on Apitte, but for testing i need to use some mock responses.

What are you using? www.apiary.io or https://www.soapui.org/…cev-pro.html

Or is there an option how to test it against the localhost? I mean can i somehowe responses write into comments of open api definitions? And use this responses?

Also i would like to say, that when i build new application and i have a business meeting i need some use case, so mocking api is the best for testing UI and negotiate with customer.

Thanks for answers

dkorpar
Member | 136
+
0
-

If U're using guzzle, you can check out this option
https://blog.nikolaposa.in.rs/…ock-handler/
it is certainly much faster then actually making requests to some other api, works offline and with few helper functions should be easy…

Last edited by dkorpar (2019-09-09 10:58)