diff --git a/bin/options.js b/bin/options.js index 41f7222a62..60cbcd705e 100644 --- a/bin/options.js +++ b/bin/options.js @@ -40,8 +40,8 @@ function getOptions() { process.argv = process.argv .slice(0, 2) .concat(opts.concat(process.argv.slice(2))); - } catch (err) { - // ignore + } catch (ignore) { + // NOTE: should console.error() and throw the error } process.env.LOADED_MOCHA_OPTS = true; diff --git a/lib/browser/progress.js b/lib/browser/progress.js index 0dcb341898..7bf400b58e 100644 --- a/lib/browser/progress.js +++ b/lib/browser/progress.js @@ -112,7 +112,7 @@ Progress.prototype.draw = function(ctx) { var w = ctx.measureText(text).width; ctx.fillText(text, x - w / 2 + 1, y + fontSize / 2 - 1); - } catch (err) { + } catch (ignore) { // don't fail if we can't render progress } return this; diff --git a/lib/runner.js b/lib/runner.js index 565d47d6e5..7ada7d1411 100644 --- a/lib/runner.js +++ b/lib/runner.js @@ -244,7 +244,7 @@ Runner.prototype.fail = function(test, err) { try { err.stack = this.fullStackTrace || !err.stack ? err.stack : stackFilter(err.stack); - } catch (ignored) { + } catch (ignore) { // some environments do not take kindly to monkeying with the stack }