MCPcopy
hub / github.com/vitest-dev/vitest / normalizeFilename

Function normalizeFilename

test/coverage-test/utils.ts:130–134  ·  view source on GitHub ↗
(filename: string)

Source from the content-addressed store, hash-verified

128}
129
130export function normalizeFilename(filename: string) {
131 return normalize(filename)
132 .replace(normalize(process.cwd()), '<process-cwd>')
133 .replace(normalize(resolve(process.cwd(), '../../')), '<project-root>')
134}
135
136export function isV8Provider() {
137 return process.env.COVERAGE_PROVIDER === 'v8'

Callers 1

readCoverageJsonFunction · 0.70

Calls 2

normalizeFunction · 0.85
resolveFunction · 0.70

Tested by

no test coverage detected