This commit is contained in:
@@ -119,8 +119,20 @@ async function openSharedSpace(page: Page) {
|
||||
return detail;
|
||||
}
|
||||
|
||||
/** Open the seeded chat in the already-open shared space; returns the conversation. */
|
||||
/**
|
||||
* Open the seeded chat in the already-open shared space; returns the conversation.
|
||||
*
|
||||
* The chat list splits by owner scope ('自分' / '他のメンバー'). The seeded chat is
|
||||
* owned by `manager`, so a viewing MEMBER finds it under '他のメンバー' (the default
|
||||
* '自分' scope hides it). The toggle only renders when others' chats exist
|
||||
* (`hasOthersTasks`), so for the OWNER (manager) it is absent and the chat is already
|
||||
* visible under '自分'. Click the others-scope tab only when it is present.
|
||||
*/
|
||||
async function openSeededChat(page: Page) {
|
||||
const othersScope = page.getByTestId('space-chat-scope-others');
|
||||
if (await othersScope.count()) {
|
||||
await othersScope.click();
|
||||
}
|
||||
const chatRow = page.locator(`[data-testid="space-chat-row"][data-task-id="${chatTaskId}"]`);
|
||||
await expect(chatRow).toBeVisible({ timeout: 15_000 });
|
||||
await chatRow.click();
|
||||
@@ -140,7 +152,7 @@ async function createAndOpenCaseSpace(page: Page, label: string) {
|
||||
await expect(titleInput).toBeVisible();
|
||||
const caseTitle = `${label}-${Date.now()}`;
|
||||
await titleInput.fill(caseTitle);
|
||||
await page.getByTestId('create-space-submit').click();
|
||||
await page.getByTestId('space-form-submit').click();
|
||||
await expect(titleInput).toHaveCount(0);
|
||||
const caseRow = rail
|
||||
.locator('[data-testid="space-row"][data-space-kind="case"]')
|
||||
|
||||
Reference in New Issue
Block a user