mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-04-19 22:09:37 +00:00
test: fix flaky bottom panel canvas interaction E2E test
Replace unreliable double-click-to-open-search-box assertion with a simple canvas click. Playwright's actionability checks already verify the element is not obscured by an invisible overlay, which is what the test intends to guard against.
This commit is contained in:
@@ -110,18 +110,11 @@ test.describe('Bottom Panel', { tag: '@ui' }, () => {
|
||||
// Ensure panel is closed
|
||||
await expect(bottomPanel.root).not.toBeVisible()
|
||||
|
||||
// Click on the canvas to interact with it (e.g. deselect all)
|
||||
const canvasCenter = await comfyPage.canvas.boundingBox()
|
||||
if (!canvasCenter) {
|
||||
test.skip()
|
||||
return
|
||||
}
|
||||
|
||||
// Double-click canvas to open search box -- proves canvas receives events
|
||||
await comfyPage.canvas.dblclick({
|
||||
position: { x: canvasCenter.width / 2, y: canvasCenter.height / 2 }
|
||||
// Click the canvas without `force` -- Playwright's actionability checks
|
||||
// will fail if an invisible overlay is intercepting pointer events.
|
||||
await comfyPage.canvas.click({
|
||||
position: { x: 100, y: 100 }
|
||||
})
|
||||
await expect(comfyPage.searchBox.input).toBeVisible()
|
||||
})
|
||||
|
||||
test('should switch from shortcuts to terminal panel', async ({
|
||||
|
||||
Reference in New Issue
Block a user