test: fix long-running http benchmarks

PR-URL: https://github.com/nodejs/node/pull/20125
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
Anatoli Papirovski 2018-04-18 12:34:04 +02:00
parent a2cf005cef
commit 957532ec61
No known key found for this signature in database
GPG Key ID: 614E2E1ABEB4B2C0
2 changed files with 5 additions and 3 deletions

View File

@ -26,7 +26,7 @@ function main({ type, len, c }) {
if (workers < 2) if (workers < 2)
return; return;
setTimeout(function() { setImmediate(function() {
const path = `/${type}/${len}`; const path = `/${type}/${len}`;
bench.http({ bench.http({
@ -36,6 +36,6 @@ function main({ type, len, c }) {
w1.destroy(); w1.destroy();
w2.destroy(); w2.destroy();
}); });
}, 100); });
}); });
} }

View File

@ -18,12 +18,14 @@ runBenchmark('http',
'chunkedEnc=true', 'chunkedEnc=true',
'chunks=0', 'chunks=0',
'dur=0.1', 'dur=0.1',
'input=keep-alive',
'key=""', 'key=""',
'len=1', 'len=1',
'method=write', 'method=write',
'n=1', 'n=1',
'res=normal', 'res=normal',
'type=asc' 'type=asc',
'value=X-Powered-By'
], ],
{ {
NODEJS_BENCHMARK_ZERO_ALLOWED: 1, NODEJS_BENCHMARK_ZERO_ALLOWED: 1,