Skip to content

[12팀 박정우][Chapter1-2] 프레임워크 없이 SPA 만들기 - Basic #376

[12팀 박정우][Chapter1-2] 프레임워크 없이 SPA 만들기 - Basic

[12팀 박정우][Chapter1-2] 프레임워크 없이 SPA 만들기 - Basic #376

Triggered via pull request October 3, 2024 14:05
Status Failure
Total duration 27s
Artifacts

ci.yml

on: pull_request_target
Fit to window
Zoom out
Zoom in

Annotations

16 errors and 4 warnings
Unhandled error: src/__tests__/chapter1-2/basic.test.jsx#L123
SyntaxError: Function statements require a function name ❯ Object.exports.getCurrentEventHandlerValue node_modules/jsdom/lib/jsdom/living/helpers/create-event-accessor.js:104:7 ❯ HTMLButtonElement.<anonymous> node_modules/jsdom/lib/jsdom/living/helpers/create-event-accessor.js:14:30 ❯ innerInvokeEventListeners node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:350:25 ❯ invokeEventListeners node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:286:3 ❯ HTMLButtonElementImpl._dispatch node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:233:9 ❯ fireAnEvent node_modules/jsdom/lib/jsdom/living/helpers/events.js:18:36 ❯ HTMLButtonElementImpl.click node_modules/jsdom/lib/jsdom/living/nodes/HTMLElement-impl.js:85:5 ❯ HTMLButtonElement.click node_modules/jsdom/lib/jsdom/living/generated/HTMLElement.js:108:34 ❯ src/__tests__/chapter1-2/basic.test.jsx:123:14 This error originated in "src/__tests__/chapter1-2/basic.test.jsx" test file. It doesn't mean the error was thrown inside the file itself, but while it was running. The latest test that might've caused the error is "이벤트 리스너를 연결해야 한다". It might mean one of the following: - The error was thrown, while Vitest was running this test. - If the error occurred after the test had been completed, this was the last documented test before it was thrown.
src/__tests__/chapter1-1/basic.test.js > 기본과제 테스트 > 1. 라우팅 구현 > 존재하지 않는 경로로 접근하면 404 페이지가 렌더링된다: src/__tests__/chapter1-1/basic.test.js#L52
AssertionError: expected '<div id="root"><div><div class="bg-gr…' to contain '404' Expected: "404" Received: "<div id="root"><div><div class="bg-gray-100 flex items-center justify-center min-h-screen"><div class="bg-white p-8 rounded-lg shadow-md w-full max-w-md"><h1 class="text-2xl font-bold text-center text-blue-600 mb-8">항해플러스</h1><form id="login-form"><input type="text" id="username" placeholder="사용자 이름" class="w-full p-2 mb-4 border rounded" required="true"><input type="password" placeholder="비밀번호" class="w-full p-2 mb-6 border rounded" required="true"><button type="submit" class="w-full bg-blue-600 text-white p-2 rounded">로그인</button></form><div class="mt-4 text-center"><a href="#" class="text-blue-600 text-sm">비밀번호를 잊으셨나요?</a></div><hr class="my-6"></div></div></div></div>" ❯ src/__tests__/chapter1-1/basic.test.js:52:39
src/__tests__/chapter1-1/basic.test.js > 기본과제 테스트 > 4. 컴포넌트 기반 구조 설계 > Header, Footer 컴포넌트가 메인 페이지와 프로필 페이지에 존재하고, 로그인페이지와 에러페이지에는 존재하지 않는다.: src/__tests__/chapter1-1/basic.test.js#L136
AssertionError: expected <header …(1)><h1 …(1)></h1></header> to be falsy - Expected: <header class="bg-blue-600 text-white p-4 sticky top-0" > <h1 class="text-2xl font-bold" > 항해플러스 </h1> </header> + Received: false ❯ src/__tests__/chapter1-1/basic.test.js:136:48
src/__tests__/chapter1-1/basic.test.js > 기본과제 테스트 > 5. 상태 관리 구현 > 로그인 상태에 따라 UI가 변경된다: src/__tests__/chapter1-1/basic.test.js#L153
AssertionError: expected '<div id="root"><div><div class="bg-gr…' to contain '로그인' Expected: "로그인" Received: "<div id="root"><div><div class="bg-gray-100 min-h-screen flex justify-center"><div class="max-w-md w-full"><header class="bg-blue-600 text-white p-4 sticky top-0"><h1 class="text-2xl font-bold">항해플러스</h1></header><nav class="bg-white shadow-md p-2 sticky top-14"><ul class="flex justify-around"><li><a href="/" class="text-gray-600" data-link="true">홈</a></li><li><a href="/profile" class="text-blue-600 font-bold" data-link="true">프로필</a></li><li><a href="#" id="logout" class="text-gray-600">로그아웃</a></li></ul></nav><main class="p-4"><div class="bg-white p-8 rounded-lg shadow-md"><h2 class="text-2xl font-bold text-center text-blue-600 mb-8">내 프로필</h2><form id="profile-form"><div class="mb-4"><label for="username" class="block text-gray-700 text-sm font-bold mb-2">사용자 이름</label><input type="text" id="username" name="username" class="w-full p-2 border rounded" value="testuser" required="true"></div><div class="mb-4"><label for="email" class="block text-gray-700 text-sm font-bold mb-2">이메일</label><input type="email" id="email" name="email" class="w-full p-2 border rounded" value="" required="true"></div><div class="mb-6"><label for="bio" class="block text-gray-700 text-sm font-bold mb-2">자기소개</label><textarea id="bio" name="bio" rows="4" class="w-full p-2 border rounded"></textarea></div><button type="submit" class="w-full bg-blue-600 text-white p-2 rounded font-bold">프로필 업데이트</button></form></div></main><footer class="bg-gray-200 p-4 text-center"><p>© 2024 항해플러스. All rights reserved.</p></footer></div></div></div></div>" ❯ src/__tests__/chapter1-1/basic.test.js:153:39
src/__tests__/chapter1-1/basic.test.js > 기본과제 테스트 > 6. 기본적인 에러 처리 > 잘못된 라우트 접근 시 404 페이지로 리다이렉션된다: src/__tests__/chapter1-1/basic.test.js#L174
AssertionError: expected '<div id="root"><div><div class="bg-gr…' to contain '404' Expected: "404" Received: "<div id="root"><div><div class="bg-gray-100 min-h-screen flex justify-center"><div class="max-w-md w-full"><header class="bg-blue-600 text-white p-4 sticky top-0"><h1 class="text-2xl font-bold">항해플러스</h1></header><nav class="bg-white shadow-md p-2 sticky top-14"><ul class="flex justify-around"><li><a href="/" class="text-gray-600" data-link="true">홈</a></li><li><a href="/profile" class="text-blue-600 font-bold" data-link="true">프로필</a></li><li><a href="#" id="logout" class="text-gray-600">로그아웃</a></li></ul></nav><main class="p-4"><div class="bg-white p-8 rounded-lg shadow-md"><h2 class="text-2xl font-bold text-center text-blue-600 mb-8">내 프로필</h2><form id="profile-form"><div class="mb-4"><label for="username" class="block text-gray-700 text-sm font-bold mb-2">사용자 이름</label><input type="text" id="username" name="username" class="w-full p-2 border rounded" value="testuser" required="true"></div><div class="mb-4"><label for="email" class="block text-gray-700 text-sm font-bold mb-2">이메일</label><input type="email" id="email" name="email" class="w-full p-2 border rounded" value="" required="true"></div><div class="mb-6"><label for="bio" class="block text-gray-700 text-sm font-bold mb-2">자기소개</label><textarea id="bio" name="bio" rows="4" class="w-full p-2 border rounded"></textarea></div><button type="submit" class="w-full bg-blue-600 text-white p-2 rounded font-bold">프로필 업데이트</button></form></div></main><footer class="bg-gray-200 p-4 text-center"><p>© 2024 항해플러스. All rights reserved.</p></footer></div></div></div></div>" ❯ src/__tests__/chapter1-1/basic.test.js:174:39
basic
Process completed with exit code 1.
src/__tests__/chapter1-2/advanced.test.jsx > Chapter1-2 > 심화과제 > Virtual DOM과 이벤트 관리 > renderElement > > 초기 렌더링이 올바르게 수행되어야 한다: src/__tests__/chapter1-2/advanced.test.jsx#L22
AssertionError: expected '' to be '<div id="test">Hello</div>' // Object.is equality - Expected + Received - <div id="test">Hello</div> ❯ src/__tests__/chapter1-2/advanced.test.jsx:22:35
src/__tests__/chapter1-2/advanced.test.jsx > Chapter1-2 > 심화과제 > Virtual DOM과 이벤트 관리 > renderElement > > diff 알고리즘을 통해 변경된 부분만 업데이트해야 한다: src/__tests__/chapter1-2/advanced.test.jsx#L45
AssertionError: expected '' to be '<div><h1>Updated Title</h1><p>Paragra…' // Object.is equality - Expected + Received - <div><h1>Updated Title</h1><p>Paragraph 1</p></div> ❯ src/__tests__/chapter1-2/advanced.test.jsx:45:35
src/__tests__/chapter1-2/advanced.test.jsx > Chapter1-2 > 심화과제 > Virtual DOM과 이벤트 관리 > renderElement > > 요소의 속성만 변경되었을 때 요소를 재사용해야 한다: src/__tests__/chapter1-2/advanced.test.jsx#L86
AssertionError: expected '' to be '<div id="test" class="new">Hello</div>' // Object.is equality - Expected + Received - <div id="test" class="new">Hello</div> ❯ src/__tests__/chapter1-2/advanced.test.jsx:86:35
src/__tests__/chapter1-2/advanced.test.jsx > Chapter1-2 > 심화과제 > Virtual DOM과 이벤트 관리 > renderElement > > 요소의 타입이 변경되었을 때 새로운 요소를 생성해야 한다: src/__tests__/chapter1-2/advanced.test.jsx#L99
AssertionError: expected '' to be '<span>Hello</span>' // Object.is equality - Expected + Received - <span>Hello</span> ❯ src/__tests__/chapter1-2/advanced.test.jsx:99:35
basic
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
basic
The following actions use a deprecated Node.js version and will be forced to run on node20: actions/checkout@v2. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
advacned
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
advacned
The following actions use a deprecated Node.js version and will be forced to run on node20: actions/checkout@v2. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/