From c8adb44c6ca8f4bdfb2e64709f153637327b49f6 Mon Sep 17 00:00:00 2001 From: Master0fFate <119829254+Master0fFate@users.noreply.github.com> Date: Sun, 22 Nov 2026 16:33:29 +0100 Subject: [PATCH] Save the Resources view through the inspector in E2E --- tests/e2e/startup.spec.ts | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/tests/e2e/startup.spec.ts b/tests/e2e/startup.spec.ts index a42602bc..d9e7a4f4 100644 --- a/tests/e2e/startup.spec.ts +++ b/tests/e2e/startup.spec.ts @@ -19,17 +19,11 @@ test('real application restarts with the Resources inspector saved before discov try { application = await launch(); const page = await application.firstWindow(); - await expect(page.locator('.app-shell')).toBeVisible(); - await page.evaluate(() => { - localStorage.setItem('pi-desktop-ui-v1', JSON.stringify({ - version: 1, - state: { - inspectorCollapsed: false, - inspectorTab: 'resources', - inspectorLastViews: { work: 'files', run: 'sessions', system: 'resources' }, - }, - })); - }); + await expect(page.locator('[data-bridge-status="ready"]')).toBeVisible(); + const inspector = page.getByRole('complementary', { name: 'Project inspector' }); + await inspector.getByRole('button', { name: 'System', exact: true }).click(); + await inspector.getByRole('tab', { name: 'Resources', exact: true }).click(); + await expect(inspector.getByText('No Pi resources loaded')).toBeVisible(); await application.close(); application = await launch(); const restored = await application.firstWindow();