Open tonioriol opened 4 years ago
Instead of mocking the api, that's a closer to real solution: http https://github.com/blueberryapps/vcr.js/
It records one interaction and stores the response, so the call happens only the first time and gets stored as json, next time it takes the json.
It might be useful. But if we think that's not "real" enough, we just use a real contentful space for that.
Reading about the yargs, found that, it might be useful: https://github.com/yargs/yargs/blob/master/docs/advanced.md#testing-a-command-module
Instead of mocking the api, that's a closer to real solution: http https://github.com/blueberryapps/vcr.js/
It records one interaction and stores the response, so the call happens only the first time and gets stored as json, next time it takes the json.
It might be useful. But if we think that's not "real" enough, we just use a real contentful space for that.