MCPcopy
hub / github.com/vitejs/vite / readFixture

Function readFixture

packages/vite/src/node/ssr/__tests__/ssrTransform.spec.ts:638–645  ·  view source on GitHub ↗
(filename: string)

Source from the content-addressed store, hash-verified

636 expect(sources).toContain('./second.ts')
637
638 function readFixture(filename: string) {
639 const url = new URL(
640 `./fixtures/bundled-with-sourcemaps/${filename}`,
641 import.meta.url,
642 )
643
644 return readFileSync(fileURLToPath(url), 'utf8')
645 }
646})
647
648test('sourcemap with multiple sources and nested paths', async () => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected