erikengervall/dockest

Please flesh out the use case

Closed this issue · 2 comments

This looks interesting but from looking through the readme, it's still not entirely clear to me what it does.

Dockest is an integration testing tool aimed at alleviating the process of evaluating unit tests whilst running multi-container Docker applications.

My best guess would be that it spins up your app in Docker containers (with optional database) before running your Jest-based integration tests against it. Is that right? What does it provide over plain docker-compose?

An example of a really simple app with tests and Dockest config would be really helpful. Thanks. 🙏

Hey, thanks for your comment!

Here's a blog post from mid June explaining the initial motivation for the library: https://engineering.klarna.com/node-js-integration-testing-with-ease-fab5f8d29163.

Various examples can be found in the example folder (https://github.com/erikengervall/dockest/tree/master/example) :)

Your comment does shine a light on the fact that these are not referenced in the documentation. I'm in the midst of improving the documentation and will make sure it's included!

The value that Dockest provides over e.g. plain docker-compose is that it figures out the connectivity and responsiveness status of each individual service (either synchronously or asynchronously) and once all services are ready the tests run.

Feel free to get back to me if you feel there's still documentation missing!