test: account for alternateScreen flag in empty headless snapshot assertions

The alt-screen scrollback fix threads an alternateScreen flag through the
headless snapshot return type. Two sibling empty-buffer tests used exact
toEqual() assertions that did not include the new (legitimately false) key.
Update them to reflect the correct snapshot shape.
This commit is contained in:
brennanb2025
2026-06-27 22:58:21 -07:00
parent a0de430397
commit 9d3c332607
2 changed files with 8 additions and 2 deletions
@@ -227,7 +227,10 @@ describe('mobile subscribe integration', () => {
cols: 90,
rows: 30,
seq: 17,
source: 'headless'
source: 'headless',
// Non-alt-screen buffer reports alternateScreen=false so the renderer
// keeps its destructive scrollback clear on restore.
alternateScreen: false
})
await expect(runtime.serializeTerminalBuffer('pty-empty')).resolves.toBeNull()
})
+4 -1
View File
@@ -5267,7 +5267,10 @@ describe('OrcaRuntimeService', () => {
cols: 90,
rows: 30,
seq: 17,
source: 'headless'
source: 'headless',
// Non-alt-screen buffer reports alternateScreen=false so the renderer
// keeps its destructive scrollback clear on restore.
alternateScreen: false
})
expect(serializeBuffer).not.toHaveBeenCalled()
})