(qualifiedName: string)
| 4438 | } |
| 4439 | |
| 4440 | function callerNamesOf(qualifiedName: string): string[] { |
| 4441 | const target = cg.getNodesByKind('method').find((n) => n.qualifiedName === qualifiedName); |
| 4442 | if (!target) return []; |
| 4443 | const names = cg |
| 4444 | .getIncomingEdges(target.id) |
| 4445 | .filter((e) => e.kind === 'calls') |
| 4446 | .map((e) => cg.getNode(e.source)?.name) |
| 4447 | .filter((n): n is string => !!n); |
| 4448 | return [...new Set(names)].sort(); |
| 4449 | } |
| 4450 | |
| 4451 | it('resolves singleton chains and auto locals to the right class, never the first-sorted one', async () => { |
| 4452 | // Two classes share writeLog; Logger sorts first so it wins any name-only |
no test coverage detected