You are right, this code doesn't work on Windows. Can you make this change as a separate commit and add a test for it? This is a great fix for Windows watching!

but I don't wanna make it a part of "fixing tests to run on windows commit", because this is actually a production code fix

the DIR_SEP at the end is useless, you could leave `'/'` there because that's a fallback if you have a pattern in root (eg. `/*.js`) in which case you need to watch the root. This however won't work on Windows, but that's not a problem, because this fallback should never happen on Win (it's gonna be `C:\**.js`, in which case `C:\` will be watched)

I think your solution should work even if the path contains both `\` and `/`, what could be a problem?