Repository navigation
Commit 402e25d
committed
#1912 review rows: the JSON fixture now speaks the spelling the writer resolves to
platform-unit-test (windows-latest) failed on d3dd922 in zoo-code:test:misc with six failing rows in
utils/__tests__/safeWriteJson.test.ts - 'Test Files 1 failed | 118 passed | 1 skipped', 'Tests 6 failed
| 2117 passed | 13 skipped'. One is mine and old-format, three are mine, two are pre-existing rows that
were green at the parent:
should preserve backups when another backup stat fails with EACCES - promise resolved, not rejected
should preserve backups when another backup stat fails with EIO - promise resolved, not rejected
propagates a transient ancestor lookup failure instead of reporting a replaced ancestor - same
reports what the target resolves to now when it no longer resolves to the pinned target - expected
'C:\Users\RUNNER~1\AppData\Local\Temp\...' and received 'C:\Users\runneradmin\...'
aborts the publish when the target's mode cannot be read - the injected stat failure never fired
keeps the published target with its new content when the post-commit directory fsync fails - 'expected
0 to be greater than 0' for the directory handles the row collected from openSync
One cause for all six. This runner reports the profile directory in its 8.3 form through os.tmpdir()
(C:\Users\RUNNER~1\...) and in its long form through fs.realpath (C:\Users\runneradmin\...), and the two
spellings name the same directory - the fourth row's assertion above is that measurement, one value
captured with fs.realpathSync and the other returned by the writer. The writer works on the realpath
spelling, and this unit moved the recovery scan onto the lock key, which is a realpath result. Every
path-keyed double in the file compares against strings derived from the fixture's mkdtemp path, so on
that runner the injections landed on paths the writer never named and the fsync row's handle filter
matched nothing. The same six rows pass on ubuntu (no 8.3 mapping) and on this box (the profile name is
'eason', whose 8.3 form is identical), which is why the failure was invisible locally - a green local
run was evidence about this machine, not about the pull request.
The fixture root is canonicalised once in beforeEach with the same call the writer uses, so the
fixture's paths and the writer's paths are one string, instead of loosening the six rows or teaching
each double to fold spellings.
Re-run here (cwd src, node 22.23.4 win32):
vitest run --config vitest.misc.config.ts: exit 0, Test Files 118 passed 1 skipped, Tests 2119 passed
13 skipped.
vitest run --config vitest.misc.config.ts --coverage (the ubuntu arm's command): exit 0, same counts.
prettier --check and eslint --max-warnings=0 --no-warn-ignored --no-cache on the changed file: exit 0.
tsc --noEmit -p tsconfig.json: exit 2, one line - activate/registerCommands.ts(88,102): error TS2739,
unchanged.
One test file changed; no production file changed in this commit.1 parent d3dd922 commit 402e25d
1 file changed
Lines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
86 | | - | |
87 | | - | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
88 | 97 | | |
89 | 98 | | |
90 | 99 | | |
| |||
0 commit comments