summaryrefslogtreecommitdiff
path: root/jstests
diff options
context:
space:
mode:
authorKristina <kristina@10gen.com>2011-05-18 10:45:52 -0400
committerKristina <kristina@10gen.com>2011-05-18 10:47:43 -0400
commitb0f4f5b42777ccd9fc453ddd2484ac0d82edeea6 (patch)
tree782ab49c1cb084542d3d847f0de7b40ef90b4d15 /jstests
parentaa0865f65528a88f545b1dee8517e1e326ad8390 (diff)
downloadmongo-b0f4f5b42777ccd9fc453ddd2484ac0d82edeea6.tar.gz
catch strings on rs.initiate()
Diffstat (limited to 'jstests')
-rw-r--r--jstests/replsets/reconfig.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/jstests/replsets/reconfig.js b/jstests/replsets/reconfig.js
index 6e144a02272..a0191b66bd2 100644
--- a/jstests/replsets/reconfig.js
+++ b/jstests/replsets/reconfig.js
@@ -46,3 +46,14 @@ var config = master.getDB("local").system.replset.findOne();
assert.eq(oldVersion, config.version);
replTest.stopSet();
+
+replTest2 = new ReplSetTest({name : 'testSet2', nodes : 1});
+nodes = replTest2.startSet();
+
+result = nodes[0].getDB("admin").runCommand({replSetInitiate : {_id : "testSet2", members : [
+ {_id : 0, tags : ["member0"]}
+ ]}});
+
+assert(result.errmsg.match(/bad or missing host field/));
+
+replTest2.stopSet();