-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
Description
Summary
The test/live-reload.test.js file was added for testing live reload functionality but doesn't follow the established testing conventions in this codebase.
Issues identified (from Copilot review)
- Cross-platform compatibility: Uses hardcoded
/tmpinstead ofos.tmpdir() - Test framework: Uses custom test runner instead of
node:test(describe/it/before/after) like other tests - Test helpers: Doesn't use
test/helpers.jsutilities (startTestServer, stopTestServer, etc.) - Cleanup: Error handlers don't always clean up temp files/directories
- Port handling: Uses hardcoded port 9876 instead of port 0 with OS assignment
Suggested changes
- Rewrite to use
node:testframework - Use test helpers from
test/helpers.js - Use
os.tmpdir()for cross-platform temp directories - Add proper cleanup in all code paths
- Consider adding public mode subscription test to
test/notifications.test.js
Reference
PR #113 review comments
Reactions are currently unavailable