Mocha test breaking watch pipe
Closed this issue · 3 comments
UltCombo commented
Looks like a mocha test timeout can kill npm run dev
with an unhandled stream error, as seen while developing Harmonic:
CLI
√ should display an error for unknown commands (640ms)
√ should init a new Harmonic site (724ms)
√ should build the Harmonic site (1053ms)
postspath is not defined
1) should create and build a new post
helpers
parser
3 passing (8s)
1 failing
1) CLI should create and build a new post:
Error: timeout of 5000ms exceeded
at null.<anonymous> (C:\repos\harmonic\node_modules\gulp-mocha\node_modules\mocha\lib\runnable.js:159:19)
at Timer.listOnTimeout (timers.js:110:15)
UltCombo commented
This is actually not easy to reproduce, I've managed to reproduce a similar issue by failing Mocha's "after all" hook due to a child process holding a lock on the file system. Looks like the stream is not being implicitly associated with gulp-batch's domain for some reason.
UltCombo commented
This is probably fixed in the 2.0 branch, I'll test it on Harmonic again when I have more time.
jaydson commented
👍