MCPcopy Create free account
hub / github.com/garrytan/gstack / runScript

Function runScript

test/readme-throughput.test.ts:37–48  ·  view source on GitHub ↗
(cwd: string)

Source from the content-addressed store, hash-verified

35});
36
37function runScript(cwd: string): { stdout: string; stderr: string; status: number } {
38 const res = spawnSync('bun', ['run', SCRIPT], {
39 encoding: 'utf-8',
40 cwd,
41 env: { ...process.env },
42 });
43 return {
44 stdout: (res.stdout ?? '').trim(),
45 stderr: (res.stderr ?? '').trim(),
46 status: res.status ?? -1,
47 };
48}
49
50describe('update-readme-throughput script', () => {
51 test('happy path: JSON present → anchor replaced with number', () => {

Callers 1

Calls 1

spawnSyncFunction · 0.85

Tested by

no test coverage detected