MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / run

Function run

__tests__/migration-concurrent-opens.test.ts:130–143  ·  view source on GitHub ↗
(args: string[])

Source from the content-addressed store, hash-verified

128 }
129
130 function run(args: string[]): Child {
131 const child = spawn(process.execPath, args, {
132 stdio: ['pipe', 'pipe', 'ignore'],
133 // Off the fixture, so a child still exiting cannot hold it (Windows EBUSY).
134 cwd: os.tmpdir(),
135 windowsHide: true,
136 });
137 let out = '';
138 child.stdout!.on('data', (chunk) => { out += String(chunk); });
139 const exited = new Promise<number | null>((resolve) => child.once('exit', (code) => resolve(code)));
140 const handle = { child, output: () => out, exited };
141 children.push(handle);
142 return handle;
143 }
144
145 async function says(who: Child, word: string): Promise<void> {
146 const deadline = Date.now() + 30_000;

Calls 4

spawnFunction · 0.85
pushMethod · 0.80
resolveFunction · 0.70
onMethod · 0.65

Tested by

no test coverage detected