Ask HN: Best Way to Mock APIs in 2020?
11–20 of 63 posts
Re: Ask HN: Best Way to Mock APIs in 2020?
#12Re: Ask HN: Best Way to Mock APIs in 2020?
#13Automatically generates REST & GraphQL APIs within seconds from your database schema.
Here is a demo on how to create 8000+ REST APIs within 10 seconds - https://youtu.be/NtCwnlLudnk
Not just mock - you may even consider writing the full backend on it.
Im the creator - happy to answer any questions.
edit : added demo link
Re: Ask HN: Best Way to Mock APIs in 2020?
#14Can someone explain to me what this is all about? Shouldn't you hide all your API calls behind an interface, and then mock that interface? Dependency inversion principle, depend upon abstractions and all that.
If the only reason for abstraction is testing, then mocking an interface seems like a more valid choice to me.
Re: Ask HN: Best Way to Mock APIs in 2020?
#15Can someone explain to me what this is all about? Shouldn't you hide all your API calls behind an interface, and then mock that interface? Dependency inversion principle, depend upon abstractions and all that.
I personally am not a fan of too many abstractions. If the only reason for abstraction is testing, then mocking an interface seems like a more valid choice to me.
Re: Ask HN: Best Way to Mock APIs in 2020?
#16Re: Ask HN: Best Way to Mock APIs in 2020?
#17Re: Ask HN: Best Way to Mock APIs in 2020?
#18Can someone explain to me what this is all about? Shouldn't you hide all your API calls behind an interface, and then mock that interface? Dependency inversion principle, depend upon abstractions and all that.
I personally am not a fan of too many abstractions. If the only reason for abstraction is testing, then mocking an interface seems like a more valid choice to me.
Then you're likely in the wrong business, since most of what programming is is dealing with the various facets of one abstraction or another.
Re: Ask HN: Best Way to Mock APIs in 2020?
#19Earlier quoted context omitted.
I personally am not a fan of too many abstractions. If the only reason for abstraction is testing, then mocking an interface seems like a more valid choice to me.
> I personally am not a fan of too many abstractions. Then you're likely in the wrong business, since most of what programming is is dealing with the various facets of one abstraction or another.