4 ms·
With containerization it’s very quick to spin up test dependencies as well as part of your CICD. Why mock calls to a datastore when it’s super easy to spin up a
by ams92 2y ago
With containerization it’s very quick to spin up test dependencies as well as part of your CICD. Why mock calls to a datastore when it’s super easy to spin up an ephemeral postgresql instance to test on?
- randomdata 2y ago> Why mock calls to a datastore when it’s super easy to spin up an ephemeral postgresql instance to test on? It's actually super hard to get Postgres to fail, which is what you will be most interested in testing. Granted, you would probably use stubbing for that instead.
- UK-AL 2y agoBecause you have 40000 tests, and an in memory object means they can run in seconds. And the real thing runs in minutes.
- specialist 2y agoYup. Section "Easier to Test IO" in TFA.