MCPcopy
hub / github.com/sindresorhus/execa / testInheritNoBuffer

Function testInheritNoBuffer

test/stdio/native-inherit-pipe.js:60–65  ·  view source on GitHub ↗
(t, stdioOption, isSync)

Source from the content-addressed store, hash-verified

58test('stdio[*] output can be [3, "pipe"], encoding "buffer", sync', testInheritStdioOutput, 3, 1, [3, 'pipe'], true, 'buffer');
59
60const testInheritNoBuffer = async (t, stdioOption, isSync) => {
61 const filePath = tempfile();
62 await nestedSubprocess('nested-write.js', [filePath, foobarString], {stdin: stdioOption, buffer: false, isSync}, {input: foobarString});
63 t.is(await readFile(filePath, 'utf8'), `${foobarString} ${foobarString}`);
64 await rm(filePath);
65};
66
67test('stdin can be ["inherit", "pipe"], buffer: false', testInheritNoBuffer, ['inherit', 'pipe'], false);
68test('stdin can be [0, "pipe"], buffer: false', testInheritNoBuffer, [0, 'pipe'], false);

Callers

nothing calls this directly

Calls 1

nestedSubprocessFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…