test(e2e): scope the dashboard rail link check to the workspace rail

The rail-toggle settings test asserted on getByRole('link', { name:
'Dashboard' }), which also matches the settings section nav's own
"Dashboard" link. #1709 added waits for the settings view to unmount
first; scope the locator to .portal-rail-link as well so the assertion
cannot resolve to the settings link at all.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
4grayandClaude Opus 5.5 committed 2026-09-28 22:41:59 +02:00
1 parent af44e2368b
commit dd4bf13a91
1 file changed
+3 -4
@@ -715,10 +715,9 @@ test.describe('Electron Settings', () => {
app.mainWindow.getByTestId('dashboard-recent-sources-rail')
).toHaveCount(0);
await expect(
app.mainWindow.getByRole('link', {
name: 'Dashboard',
exact: true,
})
app.mainWindow
.getByRole('link', { name: 'Dashboard', exact: true })
.and(app.mainWindow.locator('.portal-rail-link'))
).toBeVisible();
} finally {
await closeElectronApp(app);