summaryrefslogtreecommitdiff
path: root/src/mongo
diff options
context:
space:
mode:
authorGreg Studer <greg@10gen.com>2012-12-21 19:19:37 -0500
committerGreg Studer <greg@10gen.com>2012-12-21 19:19:37 -0500
commit82e311d805824ec52244fb1f0cd27da4a68a161d (patch)
tree138d55abbc0572359e8decb73ecea5d33d85bbee /src/mongo
parent90c981c91e97e9286153269eec71e162f94f3d2d (diff)
downloadmongo-82e311d805824ec52244fb1f0cd27da4a68a161d.tar.gz
buildbot fail_point.js enable testing options in MongoRunner
Diffstat (limited to 'src/mongo')
-rwxr-xr-xsrc/mongo/shell/servers.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/mongo/shell/servers.js b/src/mongo/shell/servers.js
index 3192412f51f..47883c2649b 100755
--- a/src/mongo/shell/servers.js
+++ b/src/mongo/shell/servers.js
@@ -674,6 +674,14 @@ startMongos = function(args){
MongoRunner.startWithArgs = function(argArray, waitForConnect) {
var port = _parsePort.apply(null, argArray);
+
+ // Enable test commands.
+ // TODO: Make there only be one codepath for starting mongo processes
+ var programName = argArray[0];
+ if (jsTest.options().enableTestCommands && (programName.endsWith('mongod') || programName.endsWith('mongos'))) {
+ argArray.push.apply(argArray, ['--setParameter', 'enableTestCommands=1']);
+ }
+
var pid = _startMongoProgram.apply(null, argArray);
var conn = null;