From 9d3c332607f74906fea30e681bda89341dc4637f Mon Sep 17 00:00:00 2001 From: brennanb2025 Date: Sat, 27 Jun 2026 22:58:21 -0700 Subject: [PATCH] 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. --- src/main/runtime/mobile-subscribe-integration.test.ts | 5 ++++- src/main/runtime/orca-runtime.test.ts | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/main/runtime/mobile-subscribe-integration.test.ts b/src/main/runtime/mobile-subscribe-integration.test.ts index 9704018ec9c..ae4e0985703 100644 --- a/src/main/runtime/mobile-subscribe-integration.test.ts +++ b/src/main/runtime/mobile-subscribe-integration.test.ts @@ -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() }) diff --git a/src/main/runtime/orca-runtime.test.ts b/src/main/runtime/orca-runtime.test.ts index 3aa0b1f5688..3487ea9830c 100644 --- a/src/main/runtime/orca-runtime.test.ts +++ b/src/main/runtime/orca-runtime.test.ts @@ -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() })