File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -139,11 +139,17 @@ describe("Session Fs", async () => {
139139
140140 const eventsPath = p ( session . sessionId , "/session-state/events.jsonl" ) ;
141141 await expect . poll ( ( ) => provider . exists ( eventsPath ) ) . toBe ( true ) ;
142+ const contentBefore = await provider . readFile ( eventsPath , "utf8" ) ;
143+ expect ( contentBefore ) . not . toContain ( "checkpointNumber" ) ;
142144
143145 await session . rpc . compaction . compact ( ) ;
144146 await expect . poll ( ( ) => compactionEvent ) . toBeDefined ( ) ;
145147 expect ( compactionEvent ! . data . success ) . toBe ( true ) ;
146- expect ( compactionEvent ! . data . summaryContent ) . toContain ( "<overview>" ) ;
148+
149+ // Verify the events file was rewritten with a checkpoint via sessionFs
150+ await expect
151+ . poll ( ( ) => provider . readFile ( eventsPath , "utf8" ) )
152+ . toContain ( "checkpointNumber" ) ;
147153 } ) ;
148154} ) ;
149155
You can’t perform that action at this time.
0 commit comments