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

Function installPlatformPackage

__tests__/npm-sdk.test.ts:60–67  ·  view source on GitHub ↗
(root: string, sentinel: string)

Source from the content-addressed store, hash-verified

58}
59
60function installPlatformPackage(root: string, sentinel: string): void {
61 const pkgRoot = path.join(root, 'node_modules', '@colbymchenry', `codegraph-${target}`);
62 writeFakeLib(path.join(pkgRoot, 'lib', 'dist'), sentinel);
63 fs.writeFileSync(
64 path.join(pkgRoot, 'package.json'),
65 JSON.stringify({ name: `@colbymchenry/codegraph-${target}`, version: VERSION }) + '\n'
66 );
67}
68
69// require() the SDK in a child process so each case gets a fresh module cache.
70function requireSdk(mainPkg: string, env: Record<string, string> = {}) {

Callers 1

npm-sdk.test.tsFile · 0.85

Calls 2

writeFakeLibFunction · 0.85
joinMethod · 0.45

Tested by

no test coverage detected