diff --git a/desktop/e2e/session-work-ledger.spec.ts b/desktop/e2e/session-work-ledger.spec.ts index 23658e6ae7..051a1852f6 100644 --- a/desktop/e2e/session-work-ledger.spec.ts +++ b/desktop/e2e/session-work-ledger.spec.ts @@ -6,7 +6,7 @@ import { setAgentState } from "../../web/e2e/fixture-agents"; import { continueFixtureTranscript } from "../../web/e2e/pane-fixture"; import { FIRST_GOAL, NEXT_GOAL, nextWork, seedFirstWork, workFixture, workRepositoryReady } from "../../web/e2e/session-work-fixture"; import { chord } from "../../web/e2e/chords"; -import { enterWorkspace, openTaskFolds, setLanePinned, showExplorer, taskRow } from "../../web/e2e/wire"; +import { enterWorkspace, hoverSettledTaskRow, openTaskFolds, setLanePinned, showExplorer, taskRow } from "../../web/e2e/wire"; import { fitWindow, launchShell, REPO, startStack, test } from "./fixture"; import { captureElectronWindow } from "./electron-window"; import { finishNative } from "./native-teardown"; @@ -43,7 +43,8 @@ test("@platform session records by goal flow, ended work and search render in bo const child = delegated!; const root = await taskRow(page, pane, FIRST_GOAL); const tasks = page.locator("[data-task-lens]"); - await root.hover(); + // The core settles the root among the resting ones once its child has ended; a hover before that is lost when the row moves. + await hoverSettledTaskRow(root, "resting"); await page.locator(`[data-task-record="${pane}"]`).click(); // The record opens in the lane's 보기 slot (PRD sidebar-task-lens B15). const record = page.locator('aside[data-lane="detail"][data-detail="record"] [data-session-record="lane"]'); @@ -117,7 +118,8 @@ test("@platform session records by goal flow, ended work and search render in bo await page.keyboard.press("Escape"); } // Resolve from the row's ⋯ menu puts the task under 쉬는 중 once it is saved (B18). - await root.hover(); + // The summaries turned back on, the record's ask returns and the core moves the row to 내 차례; the menu opens on that row. + await hoverSettledTaskRow(root, "needs_you"); await page.locator(`[data-task-more="${pane}"]`).click(); await page.locator(`[data-task-menu="${pane}"] [data-menu-item="resolve"]`).click(); await expect(tasks.locator('[data-task-fold="rest"]')).toBeVisible({ timeout: 30_000 }); diff --git a/web/e2e/session-panel.spec.ts b/web/e2e/session-panel.spec.ts index 049b0427bd..e46fe80bec 100644 --- a/web/e2e/session-panel.spec.ts +++ b/web/e2e/session-panel.spec.ts @@ -9,7 +9,7 @@ import { agentReading, sessionIn, setAgentState, startAgentInProject, takeOverSe import { claudeProjects, continueFixtureTranscript, writeFixtureTranscript, type FixtureLabel } from "./pane-fixture"; import { startHided, type Daemon } from "./hided-fixture"; import { chord } from "./chords"; -import { chooseTheme, countSent, openOtherCheckouts, openTaskFolds, screenshot, showTasks } from "./wire"; +import { chooseTheme, countSent, hoverSettledTaskRow, openOtherCheckouts, openTaskFolds, screenshot, showTasks } from "./wire"; import { quietFor, unchangedForFrames } from "./wait"; test.describe.configure({ timeout: 240_000 }); @@ -132,7 +132,7 @@ test("the 태스크 list groups the device's tasks, folds children and resting o await page.keyboard.press("ArrowDown"); await expect(group("needs_you").locator('[data-task-focus="row"]').first()).toBeFocused(); // B18: Resolve from the ⋯ menu is saved, and the row stays under 쉬는 중. - await row(stopped).hover(); + await hoverSettledTaskRow(row(stopped), "resting"); await tasks.locator(`[data-task-more="${stopped}"]`).click(); await page.locator(`[data-task-menu="${stopped}"] [data-menu-item="resolve"]`).click(); await expect.poll(resolved(daemon, stopped)).toBe(true); @@ -194,7 +194,7 @@ test("세션 닫기 in a task's ⋯ menu closes its pane, though its checkout is const tasks = await showTasks(page); await openTaskFolds(page); const row = tasks.locator(`[data-task-row="${behind}"]`); - await row.hover(); + await hoverSettledTaskRow(row, "resting"); await tasks.locator(`[data-task-more="${behind}"]`).click(); await page.locator(`[data-task-menu="${behind}"] [data-menu-item="close"]`).click(); await expect.poll(() => sent.get("close_pane")).toBe(1); diff --git a/web/e2e/session-tree.spec.ts b/web/e2e/session-tree.spec.ts index 9e91a5d220..ff7120de94 100644 --- a/web/e2e/session-tree.spec.ts +++ b/web/e2e/session-tree.spec.ts @@ -11,7 +11,7 @@ import { setAgentState, spawnChild } from "./fixture-agents"; import { claudeProjects, continueFixtureTranscript, writeFixtureTranscript } from "./pane-fixture"; import { startHided, type Daemon } from "./hided-fixture"; import { measure } from "./session-panel-geometry.mjs"; -import { chooseTheme, screenshot, showTasks } from "./wire"; +import { chooseTheme, hoverSettledTaskRow, screenshot, showTasks } from "./wire"; test.describe.configure({ timeout: 240_000 }); test.use({ actionTimeout: 15_000 }); @@ -86,7 +86,8 @@ test("the 태스크 list opens a five-level tree, stops the indent at three and // Branch, label and facts stay inside each row, with no part over another. expect(await measure(page)).toEqual({ partProblems: [], rowsFit: [], overflow: [] }); // Under the pointer the row's buttons take the time's place and cover nothing on the line. - await panel.locator(`[data-task-row="${root}"]`).hover(); + // The root waits on its working descendants; its buttons show only once the core has settled it there. + await hoverSettledTaskRow(panel.locator(`[data-task-row="${root}"]`), "waiting"); await expect(panel.locator(`[data-task-more="${root}"]`)).toBeVisible(); await expect(panel.locator(`[data-task-row="${root}"] [data-agent-elapsed]`)).toBeHidden(); expect(await measure(page)).toEqual({ partProblems: [], rowsFit: [], overflow: [] }); diff --git a/web/e2e/wire.ts b/web/e2e/wire.ts index 0a6946d9aa..2663acab84 100644 --- a/web/e2e/wire.ts +++ b/web/e2e/wire.ts @@ -168,6 +168,20 @@ export async function taskRow(page: Page, pane: string, goal: string): Promise { + await expect(row).toHaveAttribute("data-task-state", state, { timeout: 45_000 }); // wait-ok: the core settles the task row in its group + await row.hover(); +} + /** * The boxes of a dependency graph's cards under `scope`, once the layout * worker has placed them: until then the cards stand in plain layers, and the