ci 오류 수정
This commit is contained in:
@@ -3,6 +3,8 @@ import { render, screen, cleanup } from "@testing-library/react";
|
||||
import { PublicPageRenderer } from "@/features/editor/components/PublicPageRenderer";
|
||||
import { createFooterTemplateBlocks } from "@/app/editor/templates/footerTemplate";
|
||||
import type { Block } from "@/features/editor/state/editorStore";
|
||||
import { getEditorTemplatesMessages } from "@/features/i18n/messages/editorTemplates";
|
||||
import { DEFAULT_LOCALE } from "@/features/i18n/locale";
|
||||
|
||||
// PublicPageRenderer 푸터 템플릿 TDD
|
||||
// - footerTemplate 로 생성한 섹션이 프리뷰에서 섹션/텍스트 구조로 올바르게 렌더되는지 검증한다.
|
||||
@@ -16,8 +18,8 @@ describe("PublicPageRenderer - 푸터 템플릿", () => {
|
||||
const sectionId = "footer_preview_section";
|
||||
let i = 0;
|
||||
const createId = () => `footer_${++i}`;
|
||||
|
||||
const { blocks } = createFooterTemplateBlocks({ sectionId, createId });
|
||||
const tpl = getEditorTemplatesMessages(DEFAULT_LOCALE);
|
||||
const { blocks } = createFooterTemplateBlocks({ sectionId, createId, messages: tpl.footer });
|
||||
|
||||
render(<PublicPageRenderer blocks={blocks as Block[]} />);
|
||||
|
||||
@@ -25,9 +27,9 @@ describe("PublicPageRenderer - 푸터 템플릿", () => {
|
||||
expect(section.getAttribute("data-section-id")).toBe(sectionId);
|
||||
|
||||
expect(screen.getByText("MyLanding")).toBeTruthy();
|
||||
expect(screen.getByText("더 나은 웹사이트를 위한 최고의 선택.")).toBeTruthy();
|
||||
expect(screen.getByText(/서비스 소개/)).toBeTruthy();
|
||||
expect(screen.getByText(/문의하기/)).toBeTruthy();
|
||||
expect(screen.getByText(/© 2025 MyLanding\./)).toBeTruthy();
|
||||
expect(screen.getByText("The best choice for building better websites.")).toBeTruthy();
|
||||
expect(screen.getByText(/Product/)).toBeTruthy();
|
||||
expect(screen.getByText(/Contact/)).toBeTruthy();
|
||||
expect(screen.getByText(/ 2025 MyLanding\./)).toBeTruthy();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user