From 6f359e8dda0e3dd9cf472e4b4db6d26e4bf85817 Mon Sep 17 00:00:00 2001 From: Catarina Gamboa Date: Wed, 11 Nov 2026 16:04:30 +0000 Subject: [PATCH] Smoke test: do not wait for a verification on open when an earlier test verified the fixture The server only verifies on the first file opened, so after the state error test the smoke test waited for diagnostics that never came whenever that test's notifications had all arrived before it ended. Co-Authored-By: Claude Opus 5.5 --- client/src/test/smoke.test.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/client/src/test/smoke.test.ts b/client/src/test/smoke.test.ts index 9a35ead..7788df1 100644 --- a/client/src/test/smoke.test.ts +++ b/client/src/test/smoke.test.ts @@ -41,7 +41,9 @@ suite('Bundled LiquidJava extension', () => { const initialDiagnostics = nextFixtureDiagnostics(); const document = await vscode.workspace.openTextDocument(uri); await vscode.window.showTextDocument(document); - await initialDiagnostics; + // the server only verifies on the first file opened, so an earlier test may have verified this one + const verified = api.getState().diagnostics.some(d => vscode.Uri.file(path.resolve(d.file)).fsPath === uri.fsPath); + if (!verified) await initialDiagnostics; const manualDiagnostics = nextFixtureDiagnostics(); await vscode.commands.executeCommand('liquidjava.verify');