My thinking on MongoDB mocks is that, since it's a database, it should largely parallel MySQL (except where the difference between the two is relevant, if there are any).
In MySQL assertions we have four cases:
value, asserts equality to that value
field not included, no filtering/asserting on that field
None, asserts field IS NULL
validation.ANY, asserts field IS NOT NULL
I know Mongo assertions have the first two, maybe the first three. Is there a way to implement all four in MongoDB queries?
My thinking on MongoDB mocks is that, since it's a database, it should largely parallel MySQL (except where the difference between the two is relevant, if there are any).
In MySQL assertions we have four cases:
None
, asserts field IS NULLvalidation.ANY
, asserts field IS NOT NULLI know Mongo assertions have the first two, maybe the first three. Is there a way to implement all four in MongoDB queries?