(qualifiedName: string)
| 3395 | } |
| 3396 | |
| 3397 | function callerNamesOf(qualifiedName: string): string[] { |
| 3398 | const target = cg.getNodesByKind('method').find((n) => n.qualifiedName === qualifiedName); |
| 3399 | if (!target) return []; |
| 3400 | const names = cg |
| 3401 | .getIncomingEdges(target.id) |
| 3402 | .filter((e) => e.kind === 'calls') |
| 3403 | .map((e) => cg.getNode(e.source)?.name) |
| 3404 | .filter((n): n is string => !!n); |
| 3405 | return [...new Set(names)].sort(); |
| 3406 | } |
| 3407 | |
| 3408 | it('resolves singleton chains and auto locals to the right class, never the first-sorted one', async () => { |
| 3409 | // Two classes share writeLog; Logger sorts first so it wins any name-only |
no test coverage detected