diff options
author | Blake Oler <blake.oler@mongodb.com> | 2019-09-24 15:38:39 +0000 |
---|---|---|
committer | evergreen <evergreen@mongodb.com> | 2019-09-24 15:38:39 +0000 |
commit | 2f5feed026e1c22bce29cf2efe746d55879d4a14 (patch) | |
tree | 2915b778f207efc398462ca840c7b4557c042569 /jstests/sharding/covered_shard_key_indexes.js | |
parent | ccbc2473f57504f9ce08096efd000fb37a9e90fc (diff) | |
download | mongo-2f5feed026e1c22bce29cf2efe746d55879d4a14.tar.gz |
SERVER-42390 Allow documents in a sharded collection to not contain all shard key fields
Diffstat (limited to 'jstests/sharding/covered_shard_key_indexes.js')
-rw-r--r-- | jstests/sharding/covered_shard_key_indexes.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/jstests/sharding/covered_shard_key_indexes.js b/jstests/sharding/covered_shard_key_indexes.js index 2926fea3b1b..773a3d0927b 100644 --- a/jstests/sharding/covered_shard_key_indexes.js +++ b/jstests/sharding/covered_shard_key_indexes.js @@ -129,9 +129,9 @@ assert.commandWorked(st.shard0.getCollection(coll.toString()).insert({_id: "bad // Index without shard key query - not covered but succeeds assert.commandWorked(coll.ensureIndex({c: 1})); var explain = coll.find({c: true}).explain(true).executionStats; -assert.eq(0, explain.nReturned); +assert.eq(1, explain.nReturned); assert.eq(1, explain.totalDocsExamined); -assert.eq(1, getChunkSkips(explain.executionStages.shards[0].executionStages)); +assert.eq(0, getChunkSkips(explain.executionStages.shards[0].executionStages)); // Index with shard key query - covered and succeeds and returns result // |