test: add spawnSyncAndAssert util

PR-URL: https://github.com/nodejs/node/pull/52132
Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
This commit is contained in:
Antoine du Hamel authored and marco-ippolito committed 2024-05-03 08:30:16 +02:00
1 parent 3b41da9a56
commit 6da446d9e1
21 files changed
+77 -72

No files matched your search

@@ -15,7 +15,7 @@ skipIfSingleExecutableIsNotSupported();
const fixtures = require('../common/fixtures');
const tmpdir = require('../common/tmpdir');
const { copyFileSync, writeFileSync, existsSync } = require('fs');
const { spawnSyncAndExitWithoutError } = require('../common/child_process');
const { spawnSyncAndAssert, spawnSyncAndExitWithoutError } = require('../common/child_process');
const { join } = require('path');
const assert = require('assert');
@@ -58,7 +58,7 @@ assert(existsSync(seaPrepBlob));
generateSEA(outputFile, process.execPath, seaPrepBlob);
spawnSyncAndExitWithoutError(
spawnSyncAndAssert(
outputFile,
[ '-a', '--b=c', 'd' ],
{