summaryrefslogtreecommitdiff
path: root/jstests/noPassthrough/jsHeapLimit.js
diff options
context:
space:
mode:
authorclang-format-7.0.1 <adam.martin@10gen.com>2019-07-26 18:42:24 -0400
committerADAM David Alan Martin <adam.martin@10gen.com>2019-07-26 18:42:24 -0400
commitc1a45ebbb0530e3d0201321d725527f1eb83ffce (patch)
treef523079dc5ded3052eefbdcaae424b7502df5b25 /jstests/noPassthrough/jsHeapLimit.js
parentc9599d8610c3da0b7c3da65667aff821063cf5b9 (diff)
downloadmongo-c1a45ebbb0530e3d0201321d725527f1eb83ffce.tar.gz
Apply formatting per `clang-format-7.0.1`
Diffstat (limited to 'jstests/noPassthrough/jsHeapLimit.js')
-rw-r--r--jstests/noPassthrough/jsHeapLimit.js38
1 files changed, 18 insertions, 20 deletions
diff --git a/jstests/noPassthrough/jsHeapLimit.js b/jstests/noPassthrough/jsHeapLimit.js
index 512a79332ad..0089955c4a5 100644
--- a/jstests/noPassthrough/jsHeapLimit.js
+++ b/jstests/noPassthrough/jsHeapLimit.js
@@ -1,26 +1,24 @@
(function() {
- "use strict";
+"use strict";
- const options = {setParameter: "jsHeapLimitMB=1000"};
- const conn = MongoRunner.runMongod(options);
+const options = {
+ setParameter: "jsHeapLimitMB=1000"
+};
+const conn = MongoRunner.runMongod(options);
- // verify JSHeapLimitMB set from the shell
- var assertLimit = function() {
- assert.eq(999, getJSHeapLimitMB());
- };
- var exitCode = runMongoProgram("mongo",
- conn.host,
- "--jsHeapLimitMB",
- 999,
- "--eval",
- "(" + assertLimit.toString() + ")();");
- assert.eq(0, exitCode);
+// verify JSHeapLimitMB set from the shell
+var assertLimit = function() {
+ assert.eq(999, getJSHeapLimitMB());
+};
+var exitCode = runMongoProgram(
+ "mongo", conn.host, "--jsHeapLimitMB", 999, "--eval", "(" + assertLimit.toString() + ")();");
+assert.eq(0, exitCode);
- // verify the JSHeapLimitMB set from Mongod
- const db = conn.getDB('test');
- const res = db.adminCommand({getParameter: 1, jsHeapLimitMB: 1});
- assert.commandWorked(res);
- assert.eq(1000, res.jsHeapLimitMB);
+// verify the JSHeapLimitMB set from Mongod
+const db = conn.getDB('test');
+const res = db.adminCommand({getParameter: 1, jsHeapLimitMB: 1});
+assert.commandWorked(res);
+assert.eq(1000, res.jsHeapLimitMB);
- MongoRunner.stopMongod(conn);
+MongoRunner.stopMongod(conn);
})();