Skip to content

~95% on SimpleQA (e.g. Qwen3.6-27B on a 3090). Supports all local and cloud LLMs (llama.cpp, Ollama, Google, ...). 10+ search engines - arXiv, PubMed, your private documents. Everything Local & Encrypted.

fix(tests): resolve 4 failing Mobile Safari Playwright tests (#2401)

LearningCircuit67b1e3cefa36
diff --git a/src/local_deep_research/web/templates/auth/register.html b/src/local_deep_research/web/templates/auth/register.html
index 76e8096721..07a96ee3fb 100644
--- a/src/local_deep_research/web/templates/auth/register.html
+++ b/src/local_deep_research/web/templates/auth/register.html
@@ -182,6 +182,7 @@
.ldr-form-control {
width: 100%;
padding: 1rem 1.25rem;
+ min-height: 44px;
background: var(--bg-tertiary);
border: 1px solid var(--border-color);
border-radius: 10px;
diff --git a/tests/ui_tests/playwright/tests/all-pages-mobile.spec.js b/tests/ui_tests/playwright/tests/all-pages-mobile.spec.js
index e553841a19..8fee358127 100644
--- a/tests/ui_tests/playwright/tests/all-pages-mobile.spec.js
+++ b/tests/ui_tests/playwright/tests/all-pages-mobile.spec.js
@@ -56,7 +56,7 @@ async function waitForPageLoad(page, pageInfo) {
await page.waitForSelector('.ldr-loading-spinner', { state: 'hidden', timeout: 10000 }).catch(() => {});
} else if (pageInfo.path === '/benchmark/') {
// Wait for benchmark form to load
- await page.waitForSelector('#settings-form, form, .ldr-card', { timeout: 10000 }).catch(() => {});
+ await page.waitForSelector('#benchmark-form, form, .ldr-card', { timeout: 10000 }).catch(() => {});
} else if (pageInfo.path.includes('/metrics')) {
// Wait for metrics content to load
await page.waitForSelector('#metrics-content, .ldr-metrics-grid, .ldr-metric-card', { timeout: 10000 }).catch(() => {});
@@ -270,9 +270,9 @@ test.describe('All Pages - Content Above Mobile Nav', () => {
await page.waitForSelector('.ldr-settings-form input, .ldr-settings-form select, #settings-form input, #settings-form select', { timeout: 10000 }).catch(() => {});
} else if (pageInfo.path === '/benchmark/') {
// Wait for benchmark form to load
- await page.waitForSelector('#settings-form', { timeout: 10000 }).catch(() => {});
+ await page.waitForSelector('#benchmark-form', { timeout: 10000 }).catch(() => {});
// Wait for form inputs to fully render - benchmark has complex form content
- await page.waitForSelector('#settings-form input, #settings-form select, #settings-form textarea', { timeout: 10000 }).catch(() => {});
+ await page.waitForSelector('#benchmark-form input, #benchmark-form select, #benchmark-form textarea', { timeout: 10000 }).catch(() => {});
}
// Collapse all help panels before checking - they can expand from localStorage state
diff --git a/tests/ui_tests/playwright/tests/auth-pages-mobile.spec.js b/tests/ui_tests/playwright/tests/auth-pages-mobile.spec.js
index 2be91785e1..398ce403dd 100644
--- a/tests/ui_tests/playwright/tests/auth-pages-mobile.spec.js
+++ b/tests/ui_tests/playwright/tests/auth-pages-mobile.spec.js
@@ -287,10 +287,8 @@ test.describe('Auth Pages Mobile', () => {
const registerLink = page.locator('a[href*="register"]');
if (await registerLink.count() > 0) {
- await Promise.all([
- page.waitForURL('**/auth/register', { timeout: 15000, waitUntil: 'domcontentloaded' }),
- registerLink.click(),
- ]);
+ await registerLink.click();
+ await page.waitForURL('**/auth/register', { timeout: 15000 });
expect(page.url()).toContain('/auth/register');
}
@@ -302,10 +300,8 @@ test.describe('Auth Pages Mobile', () => {
const loginLink = page.locator('a[href*="login"]');
await expect(loginLink).toBeVisible();
- await Promise.all([
- page.waitForURL('**/auth/login', { timeout: 15000, waitUntil: 'domcontentloaded' }),
- loginLink.click(),
- ]);
+ await loginLink.click();
+ await page.waitForURL('**/auth/login', { timeout: 15000 });
expect(page.url()).toContain('/auth/login');
});
diff --git a/tests/ui_tests/playwright/tests/interactive-states.spec.js b/tests/ui_tests/playwright/tests/interactive-states.spec.js
index 8f5907c6bb..ffb37e0083 100644
--- a/tests/ui_tests/playwright/tests/interactive-states.spec.js
+++ b/tests/ui_tests/playwright/tests/interactive-states.spec.js
@@ -240,12 +240,14 @@ test.describe('Mobile More Menu - Navigation', () => {
await page.goto('/');
await waitForPageLoad(page, { path: '/' });
- // Library is a bottom nav tab, not in the "More" sheet menu
- const libraryTab = page.locator('.ldr-mobile-nav-tab[data-tab-id="library"], .ldr-mobile-bottom-nav a:has-text("Library"), .ldr-mobile-bottom-nav [href*="library"]');
+ // Wait for mobile navigation JS to finish initializing
+ await page.waitForFunction(() => window.mobileNav && window.mobileNav.initialized, { timeout: 10000 }).catch(() => {});
+
+ const libraryTab = page.locator('.ldr-mobile-nav-tab[data-tab-id="library"]');
if (await libraryTab.count() > 0) {
await libraryTab.first().click();
- await page.waitForLoadState('domcontentloaded');
+ await page.waitForURL('**/library**', { timeout: 15000 });
expect(page.url()).toContain('/library');
}
@@ -262,7 +264,7 @@ test.describe('Benchmark Form - Layout', () => {
await page.goto('/benchmark/');
await page.waitForLoadState('domcontentloaded');
// Wait for benchmark form to load
- await page.waitForSelector('#settings-form, form, .ldr-card', { timeout: 10000 }).catch(() => {});
+ await page.waitForSelector('#benchmark-form, form, .ldr-card', { timeout: 10000 }).catch(() => {});
});
test('benchmark form has no horizontal overflow', async ({ page }) => {