(cg: CodeGraph, name: string, filePath: string)
| 222 | proxyEdges(cg).filter((e) => e.target === target.id).map((e) => [cg.getNode(e.source)!.name, meta(e).matcher ?? null]) |
| 223 | ); |
| 224 | const fn = (cg: CodeGraph, name: string, filePath: string): Node => { |
| 225 | const node = cg.getNodesByName(name).find((n) => n.filePath === filePath && n.kind === 'function'); |
| 226 | if (!node) throw new Error(`no function ${name} in ${filePath}`); |
| 227 | return node; |
| 228 | }; |
| 229 | |
| 230 | it('links the routes the matcher accepts, under src/, and only from the proxy Next loads', async () => { |
| 231 | const { cg } = await project({ |
no test coverage detected