Skip to content

fix(scripts): allow validate-suite to run single test files#514

Closed
0xC3B6 wants to merge 1 commit intoEvoMap:mainfrom
0xC3B6:fix/validate-suite-single-file
Closed

fix(scripts): allow validate-suite to run single test files#514
0xC3B6 wants to merge 1 commit intoEvoMap:mainfrom
0xC3B6:fix/validate-suite-single-file

Conversation

@0xC3B6
Copy link
Copy Markdown

@0xC3B6 0xC3B6 commented Apr 26, 2026

Summary

  • Allow scripts/validate-suite.js to accept a concrete .test.js file path in addition to directory glob patterns.
  • Run Node's test runner with execFileSync() argv instead of building a shell command string.
  • Clear NODE_TEST_CONTEXT for nested validation runs so the script can be exercised from a Node test.

Root cause

expandTestGlob() treated every argument as a directory pattern, so test/mailboxStore.test.js became a readdirSync() target and failed with ENOTDIR.

Testing

  • node scripts/validate-suite.js test/mailboxStore.test.js
  • node --test test/validateSuite.test.js
  • node scripts/validate-suite.js test/validateSuite.test.js

@autogame-17
Copy link
Copy Markdown
Collaborator

Thanks @0xC3B6 — fantastic fix. We ported your change into our internal source tree and shipped it in v1.70.0-beta.5 (npm: @evomap/evolver@1.70.0-beta.5, Release: https://github.com/EvoMap/evolver/releases/tag/v1.70.0-beta.5).

Area: validate-suite single-file + execFileSync hardening
Ported commit: 4a63e91

We work primarily in a private source-of-truth repo and publish an obfuscated mirror to this public repo, so we could not merge your branch here directly; your authorship is acknowledged in the release notes and commit trailer. Really appreciate the well-scoped PR and the regression test — that made adoption trivial.

Closing in favor of the shipped release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants