Changes are removing deprecated functions from the initial mongoose.connect() call.
In the test log are still deprecated functions
// Changing this breaks the current test behaviour so I'm leaving it.
(node:11812) DeprecationWarning: collection.update is deprecated. Use updateOne, updateMany, or bulkWrite instead.
// Changing this one to deleteOne() or deleteMany() is causing the issue that these functions
// do not call any hooks. If we have no hooks we cannot delete patches when a document is deleted,
// so we are stuck with the deprecated remove()
(node:11812) DeprecationWarning: collection.remove is deprecated. Use deleteOne, deleteMany, or bulkWrite instead.
Changes are removing deprecated functions from the initial
mongoose.connect()
call. In the test log are still deprecated functions