Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ npm run dev # Run client + server in dev mode with hot reload
npm run start:client # Client only
npm run start:server-dev # Server only
npm test # Run all tests (Vitest)
npm run test:changed # Only tests affected by changes since origin/main
npm run test:coverage # Tests with coverage
npm run lint # Oxlint
npm run lint:fix # Oxlint with auto-fix
Expand All @@ -25,6 +26,8 @@ npx vitest tests/YourTest.test.ts --run
npx vitest NationAllianceBehavior --run # match by name pattern
```

While working, run `npm run test:changed` or the files you touched rather than the full suite: a few long simulation tests take most of its time and only matter when the engine changes. CI runs everything. `test:changed` follows imports, so a change to a file that tests read with `fs` (maps in `tests/testdata/`, `resources/`) can be missed; run those tests by name. A change to `package.json` or the Vitest config runs the whole suite.

## Architecture

OpenFront.io is a real-time multiplayer territorial strategy game. There are four components:
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"docs:map-generator": "cd map-generator && go doc -cmd -u -all",
"tunnel": "npm run build-prod && npm run start:server",
"test": "vitest run",
"test:changed": "vitest run --changed origin/main",
"test:matchmaking": "node tests/matchmaking/contained.mjs",
"test:matchmaking:e2e": "node tests/matchmaking/e2e.mjs",
"test:matchmaking:cancel": "node tests/matchmaking/e2e-cancel.mjs",
Expand Down
Loading