@@ -19,12 +19,12 @@ const bench = common.createBenchmark(main, {
1919 ] ,
2020 prefixPath : [ '/tmp' ] ,
2121 nFiles : [ 10 , 100 , 1000 ] ,
22- count : [ 30 ] ,
22+ n : [ 30 ] ,
2323} ) ;
2424
2525function spawnProcess ( script , bench , state ) {
2626 const cmd = process . execPath || process . argv [ 0 ] ;
27- while ( state . finished < state . count ) {
27+ while ( state . finished < state . n ) {
2828 const child = spawnSync ( cmd , script ) ;
2929 if ( child . status !== 0 ) {
3030 console . log ( '---- STDOUT ----' ) ;
@@ -39,13 +39,13 @@ function spawnProcess(script, bench, state) {
3939 bench . start ( ) ;
4040 }
4141
42- if ( state . finished === state . count ) {
43- bench . end ( state . count ) ;
42+ if ( state . finished === state . n ) {
43+ bench . end ( state . n ) ;
4444 }
4545 }
4646}
4747
48- function main ( { count , script, nFiles, prefixPath } ) {
48+ function main ( { n , script, nFiles, prefixPath } ) {
4949 script = path . resolve ( __dirname , '../../' , `${ script } .js` ) ;
5050 const optionsWithScript = [
5151 '--permission' ,
@@ -54,6 +54,6 @@ function main({ count, script, nFiles, prefixPath }) {
5454 script ,
5555 ] ;
5656 const warmup = 3 ;
57- const state = { count , finished : - warmup } ;
57+ const state = { n , finished : - warmup } ;
5858 spawnProcess ( optionsWithScript , bench , state ) ;
5959}
0 commit comments