test: replace forEach with for of
PR-URL: https://github.com/nodejs/node/pull/50602 Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
parent
43f5b22526
commit
fd4a305464
@ -104,7 +104,7 @@ const testFixtures = fixtures.path('test-runner');
|
|||||||
['--print', 'console.log("should not print")', '--test'],
|
['--print', 'console.log("should not print")', '--test'],
|
||||||
];
|
];
|
||||||
|
|
||||||
flags.forEach((args) => {
|
for (const args of flags) {
|
||||||
const child = spawnSync(process.execPath, args);
|
const child = spawnSync(process.execPath, args);
|
||||||
|
|
||||||
assert.notStrictEqual(child.status, 0);
|
assert.notStrictEqual(child.status, 0);
|
||||||
@ -112,7 +112,7 @@ const testFixtures = fixtures.path('test-runner');
|
|||||||
assert.strictEqual(child.stdout.toString(), '');
|
assert.strictEqual(child.stdout.toString(), '');
|
||||||
const stderr = child.stderr.toString();
|
const stderr = child.stderr.toString();
|
||||||
assert.match(stderr, /--test/);
|
assert.match(stderr, /--test/);
|
||||||
});
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user