diff options
author | Jonathan Abrahams <jonathan@mongodb.com> | 2016-03-09 12:17:50 -0500 |
---|---|---|
committer | Jonathan Abrahams <jonathan@mongodb.com> | 2016-03-09 12:18:14 -0500 |
commit | 4ae691e8edc87d0e3cfb633bb91c328426be007b (patch) | |
tree | 52079a593f54382ca13a2e741633eab1b6271893 /jstests/replsets/rollback_too_new.js | |
parent | a025d43f3ce2efc1fb1282a718f5d286fa0a4dc1 (diff) | |
download | mongo-4ae691e8edc87d0e3cfb633bb91c328426be007b.tar.gz |
SERVER-22468 Format JS code with approved style in jstests/
Diffstat (limited to 'jstests/replsets/rollback_too_new.js')
-rw-r--r-- | jstests/replsets/rollback_too_new.js | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/jstests/replsets/rollback_too_new.js b/jstests/replsets/rollback_too_new.js index 8f2d43bc8d7..e0a88e12f31 100644 --- a/jstests/replsets/rollback_too_new.js +++ b/jstests/replsets/rollback_too_new.js @@ -14,27 +14,31 @@ var replTest = new ReplSetTest({name: name, nodes: 3}); var nodes = replTest.nodeList(); var conns = replTest.startSet(); - replTest.initiate({"_id": name, - "members": [ - { "_id": 0, "host": nodes[0] }, - { "_id": 1, "host": nodes[1], arbiterOnly: true }, - { "_id": 2, "host": nodes[2], priority: 0 }], - "settings": { - "chainingAllowed": false - } - }); + replTest.initiate({ + "_id": name, + "members": [ + {"_id": 0, "host": nodes[0]}, + {"_id": 1, "host": nodes[1], arbiterOnly: true}, + {"_id": 2, "host": nodes[2], priority: 0} + ], + "settings": {"chainingAllowed": false} + }); var c_conn = conns[2]; var CID = replTest.getNodeId(c_conn); // get master and do an initial write var master = replTest.getPrimary(); - var options = {writeConcern: {w: 2, wtimeout: 60000}}; + var options = { + writeConcern: {w: 2, wtimeout: 60000} + }; assert.writeOK(master.getDB(name).foo.insert({x: 1}, options)); // add an oplog entry from the distant future as the most recent entry on node C var future_oplog_entry = conns[2].getDB("local").oplog.rs.find().sort({$natural: -1})[0]; future_oplog_entry["ts"] = new Timestamp(future_oplog_entry["ts"].getTime() + 200000, 1); - options = {writeConcern: {w: 1, wtimeout: 60000}}; + options = { + writeConcern: {w: 1, wtimeout: 60000} + }; assert.writeOK(conns[2].getDB("local").oplog.rs.insert(future_oplog_entry, options)); replTest.stop(CID); @@ -56,6 +60,6 @@ } }, "node C failed to fassert", 60 * 1000); - replTest.stopSet(undefined, undefined, { allowedExitCodes: [ MongoRunner.EXIT_ABRUPT ] }); + replTest.stopSet(undefined, undefined, {allowedExitCodes: [MongoRunner.EXIT_ABRUPT]}); }()); |