Closed ranielzed closed 2 years ago
@ranielzed I'm glad it's helpful!
That's a good idea and I'd love to add it.
I did have an msw
example in another repo svelte-add-vitest but it lacks explanation.
Kindly let me know if you have any good examples or ideas to demonstrate in this repo.
@davipon Thanks! Perhaps a couple of recipes for internal and external fetch calls would be great. Just to show simple examples of how msw
could work with vitest
, testing-library
, etc could all work together
@ranielzed I added msw
examples for internal and external fetch calls.
@davipon Looks good! Thank you for your work.. This serves as a good starting point for testing data calls.
I'll close this issue now :)
Thanks for setting this up! This is very helpful and encourages testing for more reliable code. Though I'm not sure if this is in scope but it would be nice if there's also a recipe for setting up msw for components that fetch data