MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / fileExists

Function fileExists

src/utils/__tests__/safeWriteJson.test.ts:96–103  ·  view source on GitHub ↗
(filePath: string)

Source from the content-addressed store, hash-verified

94
95 // Helper function to check if a file exists
96 async function fileExists(filePath: string): Promise<boolean> {
97 try {
98 await fs.access(filePath)
99 return true
100 } catch {
101 return false
102 }
103 }
104
105 // Success Scenarios
106 // Note: Since we pre-create the file in beforeEach, this test will overwrite it.

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected