blob: deed3dc407679bbec9da33a1fa04a23f25d76fe4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
// Test --setShellParameter CLI switch.
(function() {
'use strict';
function test(ssp, succeed) {
const result = runMongoProgram('./mongo', '--setShellParameter', ssp, '--nodb', '--eval', ';');
assert.eq(
0 == result, succeed, '--setShellParameter ' + ssp + 'worked/didn\'t-work unexpectedly');
}
// Whitelisted
test('disabledSecureAllocatorDomains=foo', true);
// Not whitelisted
test('enableTestCommands=1', false);
// Unknown
test('theAnswerToTheQuestionOfLifeTheUniverseAndEverything=42', false);
})();
|