diff options
author | jannaerin <golden.janna@gmail.com> | 2018-02-07 17:38:49 -0500 |
---|---|---|
committer | jannaerin <golden.janna@gmail.com> | 2018-03-09 00:40:40 -0500 |
commit | da1e0304e8eb91711ea1c78eb8f62538b53680e7 (patch) | |
tree | e55d32a40a76a39e01d8848c5a17d97ad640b18e /jstests/sharding/basic_drop_coll.js | |
parent | 0d5370783beeb4936a181dd2f69387da4b5e816c (diff) | |
download | mongo-da1e0304e8eb91711ea1c78eb8f62538b53680e7.tar.gz |
SERVER-32052 Update ShardingTest to default to starting shard servers as replica sets
Diffstat (limited to 'jstests/sharding/basic_drop_coll.js')
-rw-r--r-- | jstests/sharding/basic_drop_coll.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/jstests/sharding/basic_drop_coll.js b/jstests/sharding/basic_drop_coll.js index 1f2c1609969..4ac0105ed57 100644 --- a/jstests/sharding/basic_drop_coll.js +++ b/jstests/sharding/basic_drop_coll.js @@ -20,17 +20,17 @@ // Test dropping a sharded collection. assert.commandWorked(st.s.adminCommand({enableSharding: 'test'})); - st.ensurePrimaryShard('test', 'shard0000'); + st.ensurePrimaryShard('test', st.shard0.shardName); st.s.adminCommand({shardCollection: 'test.user', key: {_id: 1}}); st.s.adminCommand({split: 'test.user', middle: {_id: 0}}); assert.commandWorked( - st.s.adminCommand({moveChunk: 'test.user', find: {_id: 0}, to: 'shard0001'})); + st.s.adminCommand({moveChunk: 'test.user', find: {_id: 0}, to: st.shard1.shardName})); assert.writeOK(testDB.user.insert({_id: 10})); assert.writeOK(testDB.user.insert({_id: -10})); - assert.neq(null, st.d0.getDB('test').user.findOne({_id: -10})); - assert.neq(null, st.d1.getDB('test').user.findOne({_id: 10})); + assert.neq(null, st.shard0.getDB('test').user.findOne({_id: -10})); + assert.neq(null, st.shard1.getDB('test').user.findOne({_id: 10})); var configDB = st.s.getDB('config'); var collDoc = configDB.collections.findOne({_id: 'test.user'}); @@ -41,8 +41,8 @@ assert.commandWorked(testDB.runCommand({drop: 'user'})); - assert.eq(null, st.d0.getDB('test').user.findOne()); - assert.eq(null, st.d1.getDB('test').user.findOne()); + assert.eq(null, st.shard0.getDB('test').user.findOne()); + assert.eq(null, st.shard1.getDB('test').user.findOne()); // Call drop again to verify that the command is idempotent. assert.commandWorked(testDB.runCommand({drop: 'user'})); |