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

Function w

__tests__/cli-affected-test-conventions.test.ts:33–36  ·  view source on GitHub ↗
(rel: string, body: string)

Source from the content-addressed store, hash-verified

31 beforeAll(async () => {
32 dir = fs.mkdtempSync(path.join(os.tmpdir(), 'codegraph-affected-conv-'));
33 const w = (rel: string, body: string) => {
34 fs.mkdirSync(path.dirname(path.join(dir, rel)), { recursive: true });
35 fs.writeFileSync(path.join(dir, rel), body);
36 };
37 w('go.mod', 'module example.com/demo\n\ngo 1.22\n');
38 w('math.go', 'package demo\n\nfunc Add(a, b int) int { return a + b }\n');
39 w('math_test.go', 'package demo\n\nimport "testing"\n\nfunc TestAdd(t *testing.T) { if Add(1, 2) != 3 { t.Fatal("boom") } }\n');

Calls 1

joinMethod · 0.45

Tested by

no test coverage detected