summaryrefslogtreecommitdiff
path: root/jstests/core/idhack.js
diff options
context:
space:
mode:
Diffstat (limited to 'jstests/core/idhack.js')
-rw-r--r--jstests/core/idhack.js13
1 files changed, 5 insertions, 8 deletions
diff --git a/jstests/core/idhack.js b/jstests/core/idhack.js
index 292c2ed86b6..e26427f4b3c 100644
--- a/jstests/core/idhack.js
+++ b/jstests/core/idhack.js
@@ -25,9 +25,7 @@ assert.eq(8, t.findOne({_id: 2}).z, "C2");
assert.eq(8, t.findOne({_id: 3}).z, "C3");
// explain output should show that the ID hack was applied.
-var query = {
- _id: {x: 2}
-};
+var query = {_id: {x: 2}};
var explain = t.find(query).explain(true);
print("explain for " + tojson(query, "", true) + " = " + tojson(explain));
assert.eq(1, explain.executionStats.nReturned, "D1");
@@ -67,11 +65,10 @@ assert.eq({_id: 0, a: 0}, t.find({_id: 0}, {_id: 1, a: 1}).next());
// Non-simple: exclusion.
assert.eq({_id: 1, a: 1}, t.find({_id: 1}, {b: 0}).next());
-assert.eq(
- {
- _id: 0,
- },
- t.find({_id: 0}, {a: 0, b: 0}).next());
+assert.eq({
+ _id: 0,
+},
+ t.find({_id: 0}, {a: 0, b: 0}).next());
// Non-simple: dotted fields.
assert.eq({b: [{c: 1}, {c: 2}]}, t.find({_id: 0}, {_id: 0, "b.c": 1}).next());