mocha
mocha copied to clipboard
fix: watching files outside cwd
PR Checklist
- [x] Addresses an existing open issue: fixes #5355
- [x] That issue was marked as
status: accepting prs(note that I was the one that added that tag!) - [x] Steps in CONTRIBUTING.md were taken
Overview
In #5256 we changed the watched path from watchFiles to . (cwd). Nobody commented on this, and it broke this behavior. Reverting that line fixes the reported issue in the provided repro
Draft until:
- [ ] tests added
- [ ] understand why we may have wanted to make the reverted change in the first place (or confident that it was a mistake)
@mochajs/maintenance-crew would appreciate your insights here, looks like this was a recently-introduced bug but I'm certainly no expert :)
I'm no expert on this either but it looks sensible as a fix
Closing (at least for now) in favor of #5379