test(ui): wait for the automatic worker drawer

An empty roster opens the worker drawer automatically. Clicking Add
worker again targets the button behind the drawer and times out.
Wait for the drawer before checking the backend and agent commands.

The original test reproduces the CI failure. All six nodes-roster
Playwright tests pass with the visibility assertion.

Assisted-by: Codex:gpt-6
This commit is contained in:
localai-org-maint-bot committed 2026-09-27 03:08:07 +00:00
1 parent 8901b47062
commit 1d4d19eb2f
1 file changed
+1 -1
+1 -1
View File
@@ -49,7 +49,7 @@ test.describe('Nodes join command', () => {
await mockCluster(page, [])
await page.goto('/app/nodes')
await page.getByRole('button', { name: 'Add worker' }).first().click()
await expect(page.getByRole('dialog', { name: 'Add worker' })).toBeVisible({ timeout: 15_000 })
await page.getByRole('radio', { name: /^Backend$/ }).click()
const backendCli = page.locator('.p2p-cmd pre').first()
await expect(backendCli).toContainText('local-ai worker', { timeout: 15_000 })