2024-06-07 12:58:19 +02:00
|
|
|
import { test, expect } from "@playwright/test";
|
|
|
|
import { ViewerPage } from "../pages/ViewerPage";
|
|
|
|
|
|
|
|
test.beforeEach(async ({ page }) => {
|
|
|
|
await ViewerPage.init(page);
|
|
|
|
});
|
|
|
|
|
|
|
|
const singleBoardFileId = "dd5cc0bb-91ff-81b9-8004-77df9cd3edb1";
|
|
|
|
const singleBoardPageId = "dd5cc0bb-91ff-81b9-8004-77df9cd3edb2";
|
|
|
|
|
|
|
|
test("Comment is shown with scroll and valid position", async ({ page }) => {
|
|
|
|
const viewer = new ViewerPage(page);
|
|
|
|
await viewer.setupLoggedInUser();
|
2024-06-19 09:25:58 +02:00
|
|
|
await viewer.setupFileWithComments();
|
2024-06-07 12:58:19 +02:00
|
|
|
|
2024-07-01 10:28:40 +02:00
|
|
|
await viewer.goToViewer({
|
|
|
|
fileId: singleBoardFileId,
|
|
|
|
pageId: singleBoardPageId,
|
|
|
|
});
|
2024-06-07 12:58:19 +02:00
|
|
|
await viewer.showComments();
|
|
|
|
await viewer.showCommentsThread(1);
|
2024-11-27 11:28:51 +01:00
|
|
|
await expect(viewer.page.getByRole("textbox")).toBeVisible();
|
2024-06-07 12:58:19 +02:00
|
|
|
await viewer.showCommentsThread(1);
|
|
|
|
await viewer.showCommentsThread(2);
|
2024-11-27 11:28:51 +01:00
|
|
|
await expect(viewer.page.getByRole("textbox")).toBeVisible();
|
2024-06-07 12:58:19 +02:00
|
|
|
});
|