Closed ostapenko-me closed 4 years ago
@ctimmerm, can you check and merge this pr?
Thanks, this looks great :+1:
One thing I'd like to change is how the option is named. I think next to doing a 404 or passthrough when no match is found there are also other possible desired actions. If the option would be named onNoMatch
or something similar (with "passthrough"
being one option), we can later easily expand it to also have other options (e.g. "throw"
to throw an exception).
@ctimmerm, done.
I renamed passThroughByDefault
flag to onNoMatch
option. Can you check this pr?
Thanks!
This merge request solves problem from #217
I added
onNoMatch
option to MockAdapter constructor. If you setonNoMatch
option topassthrough
all requests would be forwarded over network by defaultAlso i added new bundlesize check in testing pipeline. It checks size of minified bundle on each
yarn test
run.Simple checklist:
.d.ts