chore(test): run all test suites, not just test/*.test.ts - #72
chore(test): run all test suites, not just test/*.test.ts#72stealthwhizz wants to merge 1 commit into
Conversation
The test script globbed only test/*.test.ts, so suites under src/**/__tests__/ (memory, sandbox-memory, skill-learner, task-tracker) and src/__tests__/ were never executed by `npm test`. Those files are currently it.todo() stubs, so they surface as TODO markers rather than failures — but wiring them in means any real tests added there from now on actually run in CI. Switch to recursive globs covering both locations. Suite: 27 pass, 18 todo, 0 fail.
shreyas-lyzr
left a comment
There was a problem hiding this comment.
The fix is correct. The previous glob silently dropped all tests under src/**/tests/ and any nested test/ paths. Switching to two explicit recursive globs is the right approach, and the author already verified CI stays green since the newly discovered suites are todo stubs. Nothing blocking.
shreyas-lyzr
left a comment
There was a problem hiding this comment.
Correct and minimal fix. The old glob (test/.test.ts) was silently skipping all suites under src//tests/ and the nested test//.test.ts subdirectory. The new command covers both locations with explicit recursive globs. Node's --test runner accepts multiple glob arguments and handles duplicates gracefully, so there is no risk of double-counting.
The PR description correctly notes that the newly-discovered suites are all it.todo() stubs, so CI stays green immediately after merge. This is a safe landing point.
One small observation: the glob order matters if any test suite has a --test-reporter or ordering dependency, but given these are Node's built-in test runner suites with no custom reporter config, the order is inconsequential.
Security pass: package.json script change only, no new dependencies, no credential exposure. Clean.
Problem
The test script globbed only
test/*.test.ts:So the suites under
src/**/__tests__/(memory, sandbox-memory, skill-learner, task-tracker) andsrc/__tests__/telemetry.test.tswere never executed bynpm testor CI — silently non-running tests.What I checked first
Ran those orphaned files directly. They're currently
it.todo(...)placeholder stubs with no bodies, so they report as TODO markers, not failures. That means flipping the glob is safe today (CI stays green) and, more importantly, any real tests added under those paths from now on will actually run instead of being silently ignored.Fix
Recursive globs covering both locations.
Result
npm testnow discovers every suite:27 real tests pass, 18 TODO stubs surface as TODO (not failures), 0 failures.
Follow-up flagged from #71; kept as its own one-line change.