[Snyk] Upgrade mocha from 2.5.3 to 6.2.1 #1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Snyk has created this PR to upgrade
mocha
from 2.5.3 to 6.2.1.Warning: This is a major version upgrade, and may be a breaking change.
The recommended version fixes:
Release notes
6.2.1 / 2019-09-29
🐛 Fixes
📖 Documentation
6.2.0 / 2019-07-18
🎉 Enhancements
🐛 Fixes
--file
(@gabegorelick)global
orglobals
(@pascalpp)_mocha
binary (@juergba)--timeout
/--slow
string values and duplicate arguments (@boneskull, @juergba)📖 Documentation
🔍 Coverage
--watch
options (@geigerzaehler)🔩 Other
--watch
mode behavior (@geigerzaehler)runWatch
into separate module (@geigerzaehler)mocha.min.js
file to stacktrace filter (@brian-lagerman)--exclude
to--ignore
and create alias (@boneskull)mocha.css
(@DanielRuf)6.1.4 / 2019-04-18
🔒 Security Fixes
6.1.3 / 2019-04-11
🐛 Fixes
yargs
-related global scope pollution (@inukshuk)pnpm
(@boneskull)6.1.2 / 2019-04-08
🐛 Fixes
6.1.1 / 2019-04-07
🐛 Fixes
6.1.0 / 2019-04-07
🔒 Security Fixes
🎉 Enhancements
options
parameter (@plroebuck).jsonc
extension (@sstephant)📠 Deprecations
These are soft-deprecated, and will emit a warning upon use. Support will be removed in (likely) the next major version of Mocha:
this.skip()
for "after all" hooks (@juergba)🐛 Fixes
this.skip()
in "before each" hooks (@juergba)--allow-uncaught
for uncaught exceptions thrown inside hooks (@givanse)and some regressions:
Suite
cloning by copyingroot
property (@fatso83)📖 Documentation
🔩 Other
6.0.2 / 2019-02-25
🐛 Fixes
Two more regressions fixed:
mocha.opts
(@boneskull)--require
does not break on module names that look like certainnode
flags (@boneskull)6.0.1 / 2019-02-21
The obligatory round of post-major-release bugfixes.
🐛 Fixes
These issues were regressions.
test.js
when run without arguments (@plroebuck)--ui
(@boneskull)--watch
(@boneskull)undefined
value from adescribe
callback is no longer considered deprecated (@boneskull)📖 Documentation
@mocha/docdash@2
(@tendonstrength)6.0.0 / 2019-02-18
💥 Breaking Changes
--grep
and--fgrep
are now mutually exclusive; attempting to use both will cause Mocha to fail instead of simply ignoring--grep
--compilers
is no longer supported; attempting to use will cause Mocha to fail with a link to more information-d
is no longer an alias for--debug
;-d
is currently ignored--watch-extensions
no longer impliesjs
; it must be explicitly added (@TheDancingCode)tap
reporter emits error messages (@chrmod)before
hook, subsequentbefore
hooks and tests in nested suites are now skipped (@bannmoore)lib/template.html
has moved tolib/browser/template.html
(@boneskull)mocha.opts
at a user-specified path (@plroebuck)Base
-extending reporter without aRunner
parameter will throw an exception (@craigtaub)code
property (and some will have additional metadata). SomeError
messages have changed. Please use thecode
property to checkError
types instead of themessage
property; these descriptions will be localized in the future. (@craigtaub)📠 Deprecations
These are soft-deprecated, and will emit a warning upon use. Support will be removed in (likely) the next major version of Mocha:
-gc
users should use--gc-global
insteadbin/options
should now use theloadMochaOpts
orloadOptions
(preferred) functions exported by thelib/cli/options
moduleRegarding the
Mocha
class constructor (fromlib/mocha
):color: false
instead ofuseColors: false
timeout: false
instead ofenableTimeouts: false
All of the above deprecations were introduced by #3556.
mocha.opts
is now considered "legacy"; please prefer RC file orpackage.json
overmocha.opts
.🎉 Enhancements
require
cache (@plroebuck)Enhancements introduced in #3556:
Mocha now supports "RC" files in JS, JSON, YAML, or
package.json
-based (usingmocha
property) format.mocharc.js
,.mocharc.json
,.mocharc.yaml
or.mocharc.yml
are valid "rc" file names and will be automatically loaded--config /path/to/rc/file
to specify an explicit path--package /path/to/package.json
to specify an explicitpackage.json
to read themocha
prop from--no-config
or--no-package
to completely disable loading of configuration via RC file andpackage.json
, respectivelypackage.json
mocha.opts
Node/V8 flag support in
mocha
executable:node
flags as supported by the running version ofnode
(also thanks to @demurgos)--v8-
to the flag namepackage.json
properties, ormocha.opts
--inspect
) now imply--no-timeouts
--debug
will automatically invoke--inspect
if supported by running version ofnode
Support negation of any Mocha-specific command-line flag by prepending
--no-
to the flag nameInterfaces now have descriptions when listed using
--interfaces
flagMocha
constructor supports all options--extension
is now an alias for--watch-extensions
and affects non-watch-mode test runs as well. For example, to run onlytest/*.coffee
(nottest/*.js
), you can domocha --require coffee-script/register --extensions coffee
.#3552:
tap
reporter is now TAP13-capable (@plroebuck & @mollstam)#3535: Mocha's version can now be queried programmatically via public property
Mocha.prototype.version
(@plroebuck)#3428:
xunit
reporter shows diffs (@mlucool)#2529:
Runner
now emits aretry
event when tests are retried (reporters can listen for this) (@catdad)#2962, #3111: In-browser notification support; warn about missing prereqs when
--growl
supplied (@plroebuck)🐛 Fixes
Suite#_onlyTests
andSuite#_onlySuites
(@vkarpov15)lookupFiles
andfiles
(@plroebuck)--delay
(and other boolean options) not working in all cases (@boneskull)--reporter-option
/--reporter-options
did not support comma-separated key/value pairs (@boneskull)mocharc.json
in published package (@boneskull)--no-timeouts
and--timeout 0
now does what you'd expect (@boneskull)--no-exit
option (@boneskull)SIGINT
(@boneskull)--forbid-only
and--forbid-pending
now "fail fast" when encountered on a suite (@outsideris)stdout:
prefix in browser console (@Bamieh)utils.isPromise()
(@fabiosantoscode)--bail
would not execute "after" nor "after each" hooks (@juergba)TERM=dumb
(@plroebuck)📖 Documentation
.github/CONTRIBUTING.md
(@markowsiak)slow
option (@finfin)--watch
docs (@benglass)🔩 Other
ms
userland module instead of hand-rolled solution (@gizemkeser)🧐 View latest project report
🛠 Adjust upgrade PR settings
🔕 Ignore this dependency or unsubscribe from future upgrade PRs