diff --git a/lib/watcher.js b/lib/watcher.js index 78ae30adc..f5de7e99b 100644 --- a/lib/watcher.js +++ b/lib/watcher.js @@ -94,7 +94,12 @@ exports.watch = function(patterns, excludes, fileList, usePolling) { // register events chokidarWatcher.on('add', bind(fileList.addFile)) .on('change', bind(fileList.changeFile)) - .on('unlink', bind(fileList.removeFile)); + .on('unlink', bind(fileList.removeFile)) + // If we don't subscribe; unhandled errors from Chokidar will bring Karma down + // (see GH Issue #959) + .on('error', function(e) { + log.debug(e); + }); return chokidarWatcher; };