mirror of
https://github.com/cloud-shuttle/leptos-shadcn-ui.git
synced 2025-12-23 06:10:01 +00:00
fix: Use correct sidebar locator based on actual HTML structure
- Change from generic nav/sidebar selectors to specific div.w-64.bg-card.border-r.border-border - This matches the actual sidebar structure in the demo source code - Should fix the remaining sidebar toggle test failure
This commit is contained in:
@@ -33,7 +33,7 @@ test.describe('Comprehensive Dashboard Demo E2E Tests', () => {
|
||||
});
|
||||
|
||||
test('should have proper sidebar navigation', async () => {
|
||||
const sidebar = page.locator('nav, .sidebar, [role="navigation"]').first();
|
||||
const sidebar = page.locator('div.w-64.bg-card.border-r.border-border');
|
||||
await expect(sidebar).toBeVisible();
|
||||
|
||||
// Check navigation links
|
||||
@@ -214,7 +214,7 @@ test.describe('Comprehensive Dashboard Demo E2E Tests', () => {
|
||||
await sidebarToggle.click();
|
||||
|
||||
// Check that sidebar is hidden/shown
|
||||
const sidebar = page.locator('nav, .sidebar, [role="navigation"]').first();
|
||||
const sidebar = page.locator('div.w-64.bg-card.border-r.border-border');
|
||||
await expect(sidebar).toBeVisible();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user