diff options
| author | Robert Guo <robert.guo@10gen.com> | 2016-10-06 16:34:21 -0400 |
|---|---|---|
| committer | Robert Guo <robert.guo@10gen.com> | 2016-10-13 18:07:24 -0400 |
| commit | 32bd5fcc91071b45173d7fbbdb541f562c767f5f (patch) | |
| tree | e544d37cef8179d205109fff07dd7cb09316197a /jstests/noPassthroughWithMongod | |
| parent | 3e13f3c3a984b31b7977e08a5da6c4e91918d5d4 (diff) | |
| download | mongo-32bd5fcc91071b45173d7fbbdb541f562c767f5f.tar.gz | |
SERVER-26503 fix incorrect uses of assert.throws()
Diffstat (limited to 'jstests/noPassthroughWithMongod')
| -rw-r--r-- | jstests/noPassthroughWithMongod/log_component_helpers.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/jstests/noPassthroughWithMongod/log_component_helpers.js b/jstests/noPassthroughWithMongod/log_component_helpers.js index dfe6523ac35..405b2bdaca3 100644 --- a/jstests/noPassthroughWithMongod/log_component_helpers.js +++ b/jstests/noPassthroughWithMongod/log_component_helpers.js @@ -32,8 +32,12 @@ assert.eq(mongo.getLogComponents().storage.journal.verbosity, 1); // setLogLevel - invalid argument - assert.throws(mongo.setLogLevel, [2, 24]); - assert.throws(db.setLogLevel, [2, ["array", "not.allowed"]]); + assert.throws(function() { + mongo.setLogLevel(2, 24); + }); + assert.throws(function() { + db.setLogLevel(2, ["array", "not.allowed"]); + }); // Restore originalSettings assert.commandWorked( |
