Files
2026-10-14 10:01:46 +00:00

111 lines
3.2 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
RUN v5.0.4 /home/hermes/worktrees/find-word-v0.2.3
❯ tests/game.test.ts (9 tests | 3 failed) 41ms
❯ 출제와 정답 판정 (5)
× 세 문제를 한 단계로 출제하고 혼합 응답 방식과 고유 문제를 보장한다 8ms
❯ 게임 상태·점수·경합 방지 (3)
× 세 문제를 끝내면 정답률·연속 정답·단계별 결과를 집계한다 2ms
× 시작 단계 1~5를 명시하면 세 문항 모두 같은 level/db이고 범위 밖 단계도 안전하다 2ms
⎯⎯⎯⎯⎯⎯⎯ Failed Tests 3 ⎯⎯⎯⎯⎯⎯⎯
FAIL tests/game.test.ts > 출제와 정답 판정 > 세 문제를 한 단계로 출제하고 혼합 응답 방식과 고유 문제를 보장한다
AssertionError: expected [ …(10) ] to have a length of 3 but got 10
- Expected
+ Received
- 3
+ 10
❯ tests/game.test.ts:51:23
49| it("세 문제를 한 단계로 출제하고 혼합 응답 방식과 고유 문제를 보장한다", () => {
50| const questions = createQuestions(42, "mixed");
51| expect(questions).toHaveLength(3);
| ^
52| expect(new Set(questions.map((q) => q.pattern.id)).size).toBe(3);
53| expect(new Set(questions.map((q) => q.environment.id)).size).toBe(…
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/3]⎯
FAIL tests/game.test.ts > 게임 상태·점수·경합 방지 > 세 문제를 끝내면 정답률·연속 정답·단계별 결과를 집계한다
AssertionError: expected 'ready' to be 'results' // Object.is equality
Expected: "results"
Received: "ready"
❯ tests/game.test.ts:153:25
151| state = gameReducer(state, { type: "NEXT" });
152| }
153| expect(state.phase).toBe("results");
| ^
154| expect(state.bestStreak).toBe(2);
155| expect(state.streak).toBe(0);
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[2/3]⎯
FAIL tests/game.test.ts > 시작 단계 1~5를 명시하면 세 문항 모두 같은 level/db이고 범위 밖 단계도 안전하다
AssertionError: expected [ [ 1, 6 ], [ 1, 6 ], [ 2, 3 ], …(7) ] to deeply equal [ [ 1, 6 ], [ 1, 6 ], [ 1, 6 ] ]
- Expected
+ Received
@@ -6,9 +6,37 @@
[
1,
6,
],
[
- 1,
- 6,
+ 2,
+ 3,
+ ],
+ [
+ 2,
+ 3,
+ ],
+ [
+ 3,
+ 0,
+ ],
+ [
+ 3,
+ 0,
+ ],
+ [
+ 4,
+ -3,
+ ],
+ [
+ 4,
+ -3,
+ ],
+ [
+ 5,
+ -6,
+ ],
+ [
+ 5,
+ -6,
],
]
❯ tests/game.test.ts:175:49
173| for (const level of LEVELS) {
174| const questions = createQuestions(42, "mixed", "rotate", level.id);
175| expect(questions.map(q => [q.level, q.db])).toEqual(Array(3).fill(…
| ^
176| }
177| for (const [input, expected] of [[NaN, 1], [-4, 1], [99, 5], [2.7, 3…
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[3/3]⎯
Test Files 1 failed (1)
Tests 3 failed | 6 passed (9)
Start at 07:56:19
Duration 1.22s (environment 82%, setup 9%, transform 4%, tests 4%, worker 1%, import 1%)