MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / fakeSource

Function fakeSource

graph-ui/src/impact/impact-source.test.ts:65–89  ·  view source on GitHub ↗
(over: Partial<ImpactSource> = {})

Source from the content-addressed store, hash-verified

63};
64
65function fakeSource(over: Partial<ImpactSource> = {}): ImpactSource {
66 return {
67 async changeImpact() {
68 return CHANGE;
69 },
70 async architectureOverview() {
71 return OVERVIEW;
72 },
73 async getComplexity() {
74 return [
75 {
76 name: 'createUser',
77 qualifiedName: 'p.src.services.userService.createUser',
78 complexity: 4,
79 cognitive: 2,
80 loopDepth: 0,
81 },
82 ];
83 },
84 async getFacts() {
85 return { testedBy: { value: [], state: 'inferred', evidence: [] } } as SymbolFacts;
86 },
87 ...over,
88 };
89}
90
91const readSource = async (filePath: string) =>
92 filePath === 'src/routes/users.ts' ? { source: USERS_SOURCE, truncated: false } : { source: '', truncated: false };

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected