외부 실증과 인증 화면 경계 보강

This commit is contained in:
Yun Chan 2026-08-12 15:01:21 +09:00
parent 68fd8f65a3
commit 64e1b2210d
7 changed files with 64 additions and 10 deletions

View file

@ -19,7 +19,7 @@
===================================================================== */
import { expect, test, type Page } from "@playwright/test";
import { completeOnboarding, useRealApi } from "./support";
import { completeOnboarding, expectNoHorizontalOverflow, useRealApi } from "./support";
const CONFIG_PATTERN = "**/api/auth/config";
const ME_PATTERN = "**/api/auth/me";
@ -119,6 +119,13 @@ test.describe("full sweep auth", () => {
test("secondary Google button shows the second allowed domain and starts the same google OAuth flow", async ({
page,
}) => {
await page.route(ME_PATTERN, async (route) => {
await route.fulfill({
status: 401,
contentType: "application/json",
body: JSON.stringify({ detail: "not_authenticated" }),
});
});
await fulfillConfig(page, READY_AUTH_CONFIG);
await page.route("**/api/auth/login**", async (route) => {
await route.fulfill({
@ -129,6 +136,11 @@ test.describe("full sweep auth", () => {
});
await page.goto("/login");
await page.setViewportSize({ width: 320, height: 568 });
await page.addStyleTag({
content: "html { overflow-y: scroll; scrollbar-gutter: stable; }",
});
await expectNoHorizontalOverflow(page);
const secondary = page.locator(".lg-obtn.secondary");
await expect(secondary).toBeEnabled();