Skip to content

Commit 68c4812

Browse files
jasnelladuh95
andauthored
Update test/parallel/test-benchmark-compare.js
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
1 parent 363ebf9 commit 68c4812

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

‎test/parallel/test-benchmark-compare.js‎

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ const compare = path.resolve(__dirname, '../../benchmark/compare.js');
1313
tmpdir.refresh();
1414

1515
const csv = tmpdir.resolve('compare.csv');
16-
const result = spawnSync(process.execPath, [
16+
spawnSyncAndExitWithoutError(process.execPath, [
1717
compare,
1818
'--old', process.execPath,
1919
'--new', process.execPath,
@@ -29,13 +29,14 @@ const result = spawnSync(process.execPath, [
2929
], {
3030
encoding: 'utf8',
3131
timeout: 30_000,
32+
}, {
33+
stderr: '',
34+
stdout(stdout) {
35+
assert.match(stdout, /confidence\s+improvement\s+accuracy/);
36+
assert.doesNotMatch(stdout, /"binary","filename"/);
37+
},
3238
});
3339

34-
assert.strictEqual(result.status, 0, result.stderr);
35-
assert.strictEqual(result.stderr, '');
36-
assert.match(result.stdout, /confidence\s+improvement\s+accuracy/);
37-
assert.doesNotMatch(result.stdout, /"binary","filename"/);
38-
3940
const lines = readFileSync(csv, 'utf8').trim().split('\n');
4041
const filename = path.join('buffers', 'buffer-compare-offset.js');
4142
assert.strictEqual(lines[0],

0 commit comments

Comments
 (0)