diff options
author | Jonathan Abrahams <jonathan@mongodb.com> | 2016-03-09 12:27:20 -0500 |
---|---|---|
committer | Jonathan Abrahams <jonathan@mongodb.com> | 2016-03-09 12:27:56 -0500 |
commit | 8c5ff5834ab1f61e68b7839cd99c3de1f87c2121 (patch) | |
tree | ef4d91cc230300a6a48eeeac696ca15df6db1212 /jstests/noPassthroughWithMongod/parallel_collection_scan.js | |
parent | 0875be78b405016736ff42e3a50166be7561c2f8 (diff) | |
download | mongo-8c5ff5834ab1f61e68b7839cd99c3de1f87c2121.tar.gz |
SERVER-22468 Format JS code with approved style in jstests/
Diffstat (limited to 'jstests/noPassthroughWithMongod/parallel_collection_scan.js')
-rw-r--r-- | jstests/noPassthroughWithMongod/parallel_collection_scan.js | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/jstests/noPassthroughWithMongod/parallel_collection_scan.js b/jstests/noPassthroughWithMongod/parallel_collection_scan.js index 44e5d361e45..11fa5d0bd75 100644 --- a/jstests/noPassthroughWithMongod/parallel_collection_scan.js +++ b/jstests/noPassthroughWithMongod/parallel_collection_scan.js @@ -3,27 +3,27 @@ t = db.parallel_collection_scan; t.drop(); s = ""; -while ( s.length < 10000 ) +while (s.length < 10000) s += "."; var bulk = t.initializeUnorderedBulkOp(); -for ( i = 0; i < 8000; i++ ) { - bulk.insert({ x: i, s: s }); - } +for (i = 0; i < 8000; i++) { + bulk.insert({x: i, s: s}); +} assert.writeOK(bulk.execute()); function iterateSliced() { - var res = t.runCommand( "parallelCollectionScan", { numCursors : 3 } ); - assert( res.ok, tojson( res ) ); + var res = t.runCommand("parallelCollectionScan", {numCursors: 3}); + assert(res.ok, tojson(res)); var count = 0; - for ( var i = 0; i < res.cursors.length; i++ ) { + for (var i = 0; i < res.cursors.length; i++) { var x = res.cursors[i]; - var cursor = new DBCommandCursor( db.getMongo(), x, 5 ); + var cursor = new DBCommandCursor(db.getMongo(), x, 5); count += cursor.itcount(); } return count; } -assert.eq( iterateSliced(), t.count() ); -assert.eq( iterateSliced(), i ); +assert.eq(iterateSliced(), t.count()); +assert.eq(iterateSliced(), i); |