fix(e2e): align test assertions with current popup/sidebar UI

popup.spec.ts: button text changed from "Sign in with Hanzo" to "Sign In"
sidebar.spec.ts: default tab is now chat (not tools) per sidebar.ts checkAuth
This commit is contained in:
Hanzo Dev
2026-03-27 23:38:01 -07:00
parent ace59dfc9d
commit fff2c6ec35
2 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -12,7 +12,7 @@ test.describe('Popup', () => {
// Login button should be present
const loginBtn = page.locator('#login-btn');
await expect(loginBtn).toBeVisible();
await expect(loginBtn).toContainText('Sign in with Hanzo');
await expect(loginBtn).toContainText('Sign In');
await expect(loginBtn).toBeEnabled();
});
+4 -4
View File
@@ -10,16 +10,16 @@ test.describe('Sidebar', () => {
await expect(tabBar).toBeVisible();
});
test('defaults to tools tab when not authenticated', async ({ context, extensionId }) => {
test('defaults to chat tab when not authenticated', async ({ context, extensionId }) => {
const page = await context.newPage();
await page.goto(`chrome-extension://${extensionId}/sidebar.html`);
// Wait for JS to initialize
await page.waitForTimeout(500);
// Tools tab should be active by default (no auth required)
const toolsTab = page.locator('#tab-tools');
await expect(toolsTab).toBeVisible();
// Chat tab should be active by default (shows login prompt for unauthenticated)
const chatTab = page.locator('#tab-chat');
await expect(chatTab).toBeVisible();
});
test('chat tab shows login prompt when not authenticated', async ({ context, extensionId }) => {