Expected Behavior
Running the test suite on Windows should generate all fixture fonts and continue into the Mocha suite.
Current Behavior
On Windows, npm test fails before the Mocha suite can start. test/generate-recursive-cff-font.mjs builds its output path with new URL( ./fonts/CFFRecursionTest.otf, import.meta.url).pathname. On Windows this produces a /D:/... pathname, and writeFileSync then attempts a path such as D:\D:\repo..., resulting in ENOENT.
Possible Solution
Use fileURLToPath(import.meta.url) with path.join, as the sibling fixture generators do.
Steps to Reproduce
- On Windows with Node v24.14.1 and npm 11.11.0, run npm ci in a clean checkout.
- Run npm test.
- Observe that the build steps complete, then Mocha fails while loading test/generate-recursive-cff-font.mjs.
- The error path contains a duplicated drive prefix, such as D:\D:\repo... .
Context
The existing CFF recursion regression test cannot run on Windows, reducing cross-platform test coverage.
Your Environment
- Version used: current master at the captured audit commit
- Font used: CFF recursion fixture
- Browser Name and version: not applicable
- Operating System and version: Windows worker, Node v24.14.1, npm 11.11.0
- Link to your project: not applicable
Expected Behavior
Running the test suite on Windows should generate all fixture fonts and continue into the Mocha suite.
Current Behavior
On Windows, npm test fails before the Mocha suite can start. test/generate-recursive-cff-font.mjs builds its output path with new URL( ./fonts/CFFRecursionTest.otf, import.meta.url).pathname. On Windows this produces a /D:/... pathname, and writeFileSync then attempts a path such as D:\D:\repo..., resulting in ENOENT.
Possible Solution
Use fileURLToPath(import.meta.url) with path.join, as the sibling fixture generators do.
Steps to Reproduce
Context
The existing CFF recursion regression test cannot run on Windows, reducing cross-platform test coverage.
Your Environment