Skip to content

Commit 54ae7d8

Browse files
gibfahnjasnell
authored andcommitted
test: pass env vars through to test-benchmark-http
Allows NODE_TEST_DIR to be set (necessary to avoid path length issues with common.PIPE). PR-URL: #13390 Refs: #12708 (comment) Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Refael Ackermann <refack@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
1 parent 61eb085 commit 54ae7d8

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

test/sequential/test-benchmark-http.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ const path = require('path');
2020

2121
const runjs = path.join(__dirname, '..', '..', 'benchmark', 'run.js');
2222

23+
const env = Object.assign({}, process.env,
24+
{ NODEJS_BENCHMARK_ZERO_ALLOWED: 1 });
25+
2326
const child = fork(runjs, ['--set', 'benchmarker=test-double',
2427
'--set', 'c=1',
2528
'--set', 'chunks=0',
@@ -28,7 +31,7 @@ const child = fork(runjs, ['--set', 'benchmarker=test-double',
2831
'--set', 'len=1',
2932
'--set', 'n=1',
3033
'http'],
31-
{env: {NODEJS_BENCHMARK_ZERO_ALLOWED: 1}});
34+
{env});
3235
child.on('exit', (code, signal) => {
3336
assert.strictEqual(code, 0);
3437
assert.strictEqual(signal, null);

0 commit comments

Comments
 (0)