Details
-
Bug
-
Resolution: Done
-
Major - P3
-
None
-
2.6.6
-
None
-
ALL
Description
I have a Node project with WebDriver test suite that runs 'mongo [database] --eval "db.dropDatabase();"' before each test run.
One of the tests attempts to create a duplicate record to test a
{unique : true}constraint, however the record is saved no problem. The schema is defined by Mongoose.
The same test gives duplicate key error if I don't run dropDatabase() beforehand.