mirror of
https://github.com/tiennm99/loldle.git
synced 2026-10-15 20:15:54 +00:00
test: add characterization tests for lib layer
Cover classic-mode comparison rules, game-engine state machine and localStorage persistence, and champion-data search/seeding/loading with Vitest. Storage keys are asserted literally so returning players' saved games and stats cannot silently break. Node environment with a hand-rolled localStorage stub; fixtures are four hand-written champions so the weekly data sync cannot destabilise the suite.
This commit is contained in:
1 parent
4b8bda7a1d
commit
d0c75e84b1
8 files changed
+1376
-2
No files matched your search
+5
-2
@@ -7,7 +7,9 @@
|
||||
"dev": "next dev",
|
||||
"build": "next build",
|
||||
"start": "next start",
|
||||
"lint": "eslint"
|
||||
"lint": "eslint",
|
||||
"test": "vitest run",
|
||||
"test:watch": "vitest"
|
||||
},
|
||||
"dependencies": {
|
||||
"next": "16.2.10",
|
||||
@@ -18,6 +20,7 @@
|
||||
"@tailwindcss/postcss": "^4.3.3",
|
||||
"eslint": "^9",
|
||||
"eslint-config-next": "16.2.10",
|
||||
"tailwindcss": "^4.3.3"
|
||||
"tailwindcss": "^4.3.3",
|
||||
"vitest": "^4.1.10"
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user