-
-
Notifications
You must be signed in to change notification settings - Fork 183
Closed
Labels
Description
For a lot of our tests it would be neat (or even necessary) to have some existing data in the database before running the test. One way to populate the database would be to make a general script or function, that could create all the test documents, and call that script before each test case, but I am afraid the script will be messy, and it will be difficult to create all references between documents etc.
Therefore, I am trying to figure out if I can create a complete dump of a sandbox database (maybe a subset of our already existing production database) that I can initialize the mongodb-memory-server with, before each test case?
Is that possible? and is there maybe a better way of doing this?
Ketan-iCapoTech, jackhwalters and qhaas