MCPcopy Create free account
hub / github.com/promptfoo/promptfoo / normalizeFsPath

Function normalizeFsPath

test/providers/scriptCompletion.test.ts:57–63  ·  view source on GitHub ↗
(path: fs.PathOrFileDescriptor)

Source from the content-addressed store, hash-verified

55let createHashMock: MockedFunction<typeof crypto.createHash>;
56
57function normalizeFsPath(path: fs.PathOrFileDescriptor): string {
58 if (path instanceof URL) {
59 return path.pathname;
60 }
61
62 return String(path);
63}
64
65afterEach(() => {
66 vi.restoreAllMocks();

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…