diff --git a/test/main/services/infrastructure/FileWatcher.test.ts b/test/main/services/infrastructure/FileWatcher.test.ts index ef0dd4c4..bc7984e5 100644 --- a/test/main/services/infrastructure/FileWatcher.test.ts +++ b/test/main/services/infrastructure/FileWatcher.test.ts @@ -765,8 +765,13 @@ describe('FileWatcher', () => { filePath: string ) => Promise; lastProcessedLineCount: Map; + instanceCreatedAt: number; }; + // Make the "new file after startup" case deterministic across filesystems + // whose birthtime precision can differ on CI runners. + watcherAny.instanceCreatedAt = 0; + // First read of a NEW file should detect errors (not baseline-skip) await watcherAny.detectErrorsInSessionFile('test-project', 'session-new', filePath);