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

Function indexedProject

__tests__/sqlite-open-error.test.ts:62–67  ·  view source on GitHub ↗

An indexed project, closed again.

()

Source from the content-addressed store, hash-verified

60
61/** An indexed project, closed again. */
62async function indexedProject(): Promise<{ root: string; dbPath: string }> {
63 const root = tempDir();
64 fs.writeFileSync(path.join(root, 'a.ts'), 'export function alpha(): number { return 1; }\n');
65 (await CodeGraph.init(root, { index: true })).close();
66 return { root, dbPath: getDatabasePath(root) };
67}
68
69/** A node:sqlite error as SQLite reports it. */
70function sqliteError(errcode: number, message: string): Error {

Callers 1

Calls 5

getDatabasePathFunction · 0.90
tempDirFunction · 0.70
closeMethod · 0.65
joinMethod · 0.45
initMethod · 0.45

Tested by

no test coverage detected