e2e 수정
CI / test (push) Failing after 5m19s
CI / e2e (push) Has been skipped
CI / pr_and_merge (push) Has been skipped

This commit is contained in:
2025-12-14 16:56:32 +09:00
parent d7ebc82e2a
commit 6ff6048f95
2 changed files with 24 additions and 14 deletions
+9 -6
View File
@@ -5,6 +5,13 @@ import { test, expect } from "@playwright/test";
// 에디터 E2E에서는 인증된 사용자 시나리오를 기본으로 가정한다.
// /api/auth/me 를 항상 200 으로 목 처리해, auth 가드가 /login 으로 리다이렉트하지 않도록 한다.
test.beforeEach(async ({ page }) => {
await page.addInitScript(() => {
try {
window.localStorage.clear();
} catch {
}
});
await page.route("**/api/auth/me", async (route) => {
await route.fulfill({
status: 200,
@@ -70,14 +77,10 @@ test("프로젝트 설정 패널에서 캔버스 프리셋을 변경하면 에
const presetSelect = page.getByRole("combobox", { name: "Canvas width 프리셋" });
await presetSelect.selectOption("mobile");
const mobileMaxWidth = await inner.evaluate((el) => (el as HTMLElement).style.maxWidth);
await expect(inner).toHaveCSS("max-width", "390px");
await presetSelect.selectOption("desktop");
const desktopMaxWidth = await inner.evaluate((el) => (el as HTMLElement).style.maxWidth);
expect(mobileMaxWidth).toBe("390px");
expect(desktopMaxWidth).toBe("1200px");
expect(mobileMaxWidth).not.toBe(desktopMaxWidth);
await expect(inner).toHaveCSS("max-width", "1200px");
});
test("텍스트 블록을 더블클릭해서 내용을 수정할 수 있어야 한다", async ({ page }) => {
@@ -6,6 +6,13 @@ function parsePx(value: string): number {
}
test.beforeEach(async ({ page }) => {
await page.addInitScript(() => {
try {
window.localStorage.clear();
} catch {
}
});
await page.route("**/api/auth/me", async (route) => {
await route.fulfill({
status: 200,