summaryrefslogtreecommitdiff
path: root/jstests/core/index_bounds_minkey.js
diff options
context:
space:
mode:
Diffstat (limited to 'jstests/core/index_bounds_minkey.js')
-rw-r--r--jstests/core/index_bounds_minkey.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/jstests/core/index_bounds_minkey.js b/jstests/core/index_bounds_minkey.js
index b1d244db0b7..5d2ea8b36fd 100644
--- a/jstests/core/index_bounds_minkey.js
+++ b/jstests/core/index_bounds_minkey.js
@@ -9,7 +9,7 @@ const coll = db.index_bounds_minkey;
coll.drop();
assert.commandWorked(coll.createIndex({a: 1}));
-assert.writeOK(coll.insert({a: MinKey}));
+assert.commandWorked(coll.insert({a: MinKey}));
// Test that queries involving comparison operators with MinKey are covered.
const proj = {
@@ -24,9 +24,9 @@ assertCoveredQueryAndCount({collection: coll, query: {a: {$lte: MinKey}}, projec
// Test that all documents are considered greater than MinKey, regardless of the presence of
// the queried field 'a'.
coll.remove({});
-assert.writeOK(coll.insert({a: "string"}));
-assert.writeOK(coll.insert({a: {b: 1}}));
-assert.writeOK(coll.insert({}));
+assert.commandWorked(coll.insert({a: "string"}));
+assert.commandWorked(coll.insert({a: {b: 1}}));
+assert.commandWorked(coll.insert({}));
assertCoveredQueryAndCount({collection: coll, query: {a: {$gt: MinKey}}, project: proj, count: 3});
assertCoveredQueryAndCount({collection: coll, query: {a: {$gte: MinKey}}, project: proj, count: 3});
assertCoveredQueryAndCount({collection: coll, query: {a: {$lt: MinKey}}, project: proj, count: 0});