(backend: 'kernel' | 'wasm', file: string, source: string)
| 167 | }); |
| 168 | |
| 169 | function extract(backend: 'kernel' | 'wasm', file: string, source: string): ExtractionResult { |
| 170 | if (backend === 'wasm') { |
| 171 | process.env.CODEGRAPH_KERNEL = '0'; |
| 172 | return extractFromSource(file, source, 'go'); |
| 173 | } |
| 174 | delete process.env.CODEGRAPH_KERNEL; |
| 175 | process.env.CODEGRAPH_KERNEL_LANGS = 'all'; |
| 176 | const result = tryKernelExtract(file, source, 'go'); |
| 177 | expect(result, `kernel extraction of ${file}`).not.toBeNull(); |
| 178 | return result!; |
| 179 | } |
| 180 | |
| 181 | /** Every supertype ref sits on its name, where resolution reads a package qualifier back. */ |
| 182 | function expectRefsOnTheirNames(result: ExtractionResult, source: string): void { |
no test coverage detected