Skip to content

Commit f9228d2

Browse files
authored
Fix Node test discovery (#1)
Run Node built-in tests using an explicit test-file glob and record the verified fix.
1 parent b4a4932 commit f9228d2

2 files changed

Lines changed: 32 additions & 1 deletion

File tree

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# 2026-07-10
2+
3+
## Intent
4+
5+
Fix the test command so Node's built-in test runner executes the repository's test files instead of treating the `tests` directory as a module.
6+
7+
## Changed
8+
9+
| Area | Files | Purpose |
10+
| --- | --- | --- |
11+
| Verification | `package.json` | Target `tests/*.test.mjs` explicitly in the test script |
12+
13+
## Verification
14+
15+
| Check | Result |
16+
| --- | --- |
17+
| `npm run harness:verify:project` | Passed |
18+
| `npm run type-check` | Passed |
19+
| `npm test` | Passed (9 tests) |
20+
21+
## Decisions
22+
23+
- Keep the test scope explicit and continue using Node's built-in test runner.
24+
25+
## Risks
26+
27+
- New tests must continue to use the `*.test.mjs` naming convention to be discovered by this command.
28+
29+
## Next
30+
31+
Commit and push the fix so GitHub Actions can rerun with the corrected command.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
"scripts": {
3434
"build": "tsc -p tsconfig.json",
3535
"type-check": "tsc -p tsconfig.json --noEmit",
36-
"test": "npm run build && node --test tests",
36+
"test": "npm run build && node --test tests/*.test.mjs",
3737
"verify:harness": "node scripts/verify-harness.mjs",
3838
"harness:verify:project": "npm run verify:harness",
3939
"harness:verify:workspace": "npm run type-check && npm test",

0 commit comments

Comments
 (0)