summaryrefslogtreecommitdiff
path: root/jstests/noPassthrough/timeseries_direct_remove_conflict.js
diff options
context:
space:
mode:
Diffstat (limited to 'jstests/noPassthrough/timeseries_direct_remove_conflict.js')
-rw-r--r--jstests/noPassthrough/timeseries_direct_remove_conflict.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/jstests/noPassthrough/timeseries_direct_remove_conflict.js b/jstests/noPassthrough/timeseries_direct_remove_conflict.js
index 20876bde2b4..4fa642eaeca 100644
--- a/jstests/noPassthrough/timeseries_direct_remove_conflict.js
+++ b/jstests/noPassthrough/timeseries_direct_remove_conflict.js
@@ -38,7 +38,7 @@ assert.commandWorked(
assert.contains(bucketsColl.getName(), testDB.getCollectionNames());
assert.commandWorked(coll.insert(docs[0]));
-assert.docEq(coll.find().sort({_id: 1}).toArray(), docs.slice(0, 1));
+assert.docEq(docs.slice(0, 1), coll.find().sort({_id: 1}).toArray());
let buckets = bucketsColl.find().sort({_id: 1}).toArray();
assert.eq(buckets.length, 1);
@@ -69,7 +69,7 @@ awaitInsert();
// The expected ordering is that the insert finished, then the remove deleted the bucket document,
// so there should be no documents left.
-assert.docEq(coll.find().sort({_id: 1}).toArray().length, 0);
+assert.docEq(0, coll.find().sort({_id: 1}).toArray().length);
buckets = bucketsColl.find().sort({_id: 1}).toArray();
assert.eq(buckets.length, 0);
@@ -77,7 +77,7 @@ assert.eq(buckets.length, 0);
// Now another insert should generate a new bucket.
assert.commandWorked(coll.insert(docs[2]));
-assert.docEq(coll.find().sort({_id: 1}).toArray(), docs.slice(2, 3));
+assert.docEq(docs.slice(2, 3), coll.find().sort({_id: 1}).toArray());
buckets = bucketsColl.find().sort({_id: 1}).toArray();
assert.eq(buckets.length, 1);