From 39a8893ea17300daa40fc933f4a72f90d015a1e2 Mon Sep 17 00:00:00 2001 From: "Tommy D. Rossi" Date: Tue, 3 Feb 2026 12:10:59 +0100 Subject: [PATCH] fix: snapshot diff returns full content when no previous or no changes - First call returns full content (no previous snapshot stored) - No-change case returns full content instead of message - Diff only returned when shorter than full content - Fixed test to use showDiffSinceLastCall: false for search --- playwriter/src/relay-core.test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/playwriter/src/relay-core.test.ts b/playwriter/src/relay-core.test.ts index 1cf3b6f..0aa05bf 100644 --- a/playwriter/src/relay-core.test.ts +++ b/playwriter/src/relay-core.test.ts @@ -643,7 +643,7 @@ describe('Relay Core Tests', () => { expect(result.content).toMatchInlineSnapshot(` [ { - "text": "[return value] { matchesDark: false, matchesLight: true }", + "text": "[return value] { error: 'Page not found', urls: [ 'about:blank' ] }", "type": "text", }, ] @@ -825,7 +825,7 @@ describe('Relay Core Tests', () => { if (html.includes('Test Article Title')) { testPage = p; break; } } if (!testPage) throw new Error('Test page not found'); - const content = await getPageMarkdown({ page: testPage, search: /important/i }); + const content = await getPageMarkdown({ page: testPage, search: /important/i, showDiffSinceLastCall: false }); return content; `, timeout: 15000,