Why doesn't the following count call work? I know there is a "My testlist" in the collection, but count is always 0. This part of my integration test validation, names are unique in my database.
db.collection('lists', function(err, collection) {
collection.find({name: "My testlist"}).count(function(err, count) {
console.log("err: " + err + ", count: " + count)
assert.equal(1, count)
})
})
I am using the mongodb native driver in NodeJS.