()
| 66900 | return dummySpawned; |
| 66901 | } |
| 66902 | const spawnedPromise = getSpawnedPromise(spawned); |
| 66903 | const timedPromise = setupTimeout(spawned, parsed.options, spawnedPromise); |
| 66904 | const processDone = setExitHandler(spawned, parsed.options, timedPromise); |
| 66905 | const context = { isCanceled: false }; |
| 66906 | spawned.kill = spawnedKill.bind(null, spawned.kill.bind(spawned)); |
| 66907 | spawned.cancel = spawnedCancel.bind(null, spawned, context); |
| 66908 | const handlePromise = async () => { |
| 66909 | const [{ error, exitCode, signal, timedOut }, stdoutResult, stderrResult, allResult] = await getSpawnedResult(spawned, parsed.options, processDone); |
| 66910 | const stdout = handleOutput(parsed.options, stdoutResult); |
| 66911 | const stderr2 = handleOutput(parsed.options, stderrResult); |
| 66912 | const all3 = handleOutput(parsed.options, allResult); |
| 66913 | if (error || exitCode !== 0 || signal !== null) { |
| 66914 | const returnedError = makeError({ |
| 66915 | error, |
| 66916 | exitCode, |
| 66917 | signal, |
| 66918 | stdout, |
| 66919 | stderr: stderr2, |
| 66920 | all: all3, |
| 66921 | command, |
| 66922 | escapedCommand, |
| 66923 | parsed, |
| 66924 | timedOut, |
| 66925 | isCanceled: context.isCanceled || (parsed.options.signal ? parsed.options.signal.aborted : false), |
| 66926 | killed: spawned.killed |
| 66927 | }); |
| 66928 | if (!parsed.options.reject) { |
| 66929 | return returnedError; |
| 66930 | } |
| 66931 | throw returnedError; |
| 66932 | } |
| 66933 | return { |
| 66934 | command, |
| 66935 | escapedCommand, |
| 66936 | exitCode: 0, |
| 66937 | stdout, |
| 66938 | stderr: stderr2, |
| 66939 | all: all3, |
| 66940 | failed: false, |
| 66941 | timedOut: false, |
| 66942 | isCanceled: false, |
nothing calls this directly
no test coverage detected
searching dependent graphs…