Commit Graph

1 Commits

Author SHA1 Message Date
Tibsfox
2cd0e0d8f0 test(core): add atomic write coverage structural regression guard (#1972)
Per CONTRIBUTING.md, enhancements require tests covering the enhanced
behavior. This test structurally verifies that milestone.cjs, phase.cjs,
and frontmatter.cjs do not contain bare fs.writeFileSync calls targeting
.planning/ files. All such writes must route through atomicWriteFileSync.

Allowed exceptions: .gitkeep writes (empty files) and archive directory
writes (new files, not read-modify-write).

This complements atomic-write.test.cjs which tests the helper itself.
If someone later adds a bare writeFileSync to these files without using
the atomic helper, this test will catch it.

Review feedback on #2056 from @trek-e.
2026-04-11 03:30:05 -07:00