You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current challenge I am facing is that I want to write integration tests that add and remove data from the database and I miss the safety of the Ecto.SQL.Sandbox. I would like my test suite to spin up a local database (possibly per testfile), run its test, and then shut it down once the suite is complete. I find myself thinking about how i need to configure my CI (docker with one container? docker with multiple containers? native runner?)
In other ecosystems like NodeJS, there are adapters to the test suites that can spin up an ephemeral in-memory database just for the tests.
The current challenge I am facing is that I want to write integration tests that add and remove data from the database and I miss the safety of the Ecto.SQL.Sandbox. I would like my test suite to spin up a local database (possibly per testfile), run its test, and then shut it down once the suite is complete. I find myself thinking about how i need to configure my CI (docker with one container? docker with multiple containers? native runner?)
In other ecosystems like NodeJS, there are adapters to the test suites that can spin up an ephemeral in-memory database just for the tests.
https://github.com/shelfio/jest-mongodb
https://github.com/nodkz/mongodb-memory-server
I can spin up a unique database per test file, I can configure a ReplSet for Multi-doc transactions, etc.
The text was updated successfully, but these errors were encountered: