unstale

npm / eslint-plugin-mocha

eslint-plugin-mocha

What changed in eslint-plugin-mocha 5 to 12, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.

29 breaking21 new APIs and options7 performance9 behavior and defaults2 tooling15 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

eslint-plugin-mocha 1241 changes

Breaking changes 13

  • The rule now reports imported Mocha interface methods.

    12.0.0release notes

  • ESLint v10.2.0 or later is now required.

    12.0.0release notes

  • The rule now requires done callback handling in every branch.

    12.0.0release notes

  • The setting name changed from exports to require; update configurations using the previous setting name.

    12.0.0release notes

  • The rule was renamed to no-top-level-tests; update configurations that reference the old name.

    12.0.0release notes

  • The rule was renamed to no-hooks-for-single-child; update configurations that reference the old name.

    12.0.0release notes

  • The rule now catches this.skip().

    12.0.0release notes

  • The rule was renamed to no-return-and-done; update configurations that reference the old name.

    12.0.0release notes

  • The rule was renamed to no-setup-in-suite; update configurations that reference the old name.

    12.0.0release notes

  • Its functionality moved into consistent-structure; update configurations that enable the old rule.

    12.0.0release notes

  • The no-synchronous-tests option was renamed to allowedAsyncMethods; update configurations that use the old option.

    12.0.0release notes

  • The rule was renamed to no-root-hooks; update configurations that reference the old name.

    12.0.0release notes

  • The recommended config defaults were adjusted, which may change the rules applied by this config.

    12.0.0release notes

New APIs and options 13

  • A rule for enforcing suite ordering was added.

    12.0.0release notes

  • Custom hook names are now supported.

    12.0.0release notes

  • Custom exports wrapper functions are now supported.

    12.0.0release notes

  • A rule for limiting retry settings was added.

    12.0.0release notes

  • A rule for limiting slow test settings was added.

    12.0.0release notes

  • A rule for limiting timeout settings was added.

    12.0.0release notes

  • A rule forbidding async callbacks that use done was added.

    12.0.0release notes

  • A rule for detecting async operations in synchronous tests was added.

    12.0.0release notes

  • A rule to reject code after done() was added.

    12.0.0release notes

  • A rule for detecting conditional tests was added.

    12.0.0release notes

  • A rule to reject multiple done() calls was added.

    12.0.0release notes

  • A rule for detecting nested suites was added.

    12.0.0release notes

  • An allow option was added to no-setup-in-describe, now named no-setup-in-suite.

    12.0.0release notes

Behavior and default changes 6

Tooling 1

Fixes and other changes 8

  • Fixes the rule for object property callbacks.

    12.0.2release notes

  • Fixes handle-done-callback for nested callback handoffs.

    12.0.1release notes

  • Usage of Mocha interface methods that are not configured is no longer flagged.

    12.0.0release notes

  • An autofix was added.

    12.0.0release notes

  • The rule now handles TypeScript this parameters.

    12.0.0release notes

  • The fixer now guards against await expressions.

    12.0.0release notes

  • Fixed the fixer for commented concise bodies.

    12.0.0release notes

  • Fixed false positives for nested functions.

    12.0.0release notes

eslint-plugin-mocha 1116 changes

Breaking changes 9

  • Disallows extra properties in rule options.

    11.3.0release notes

  • Rules ending in -description were renamed to end in -title, so configurations using the old rule names must be updated.

    11.0.0release notes

  • The package switched to ESM.

    11.0.0release notes

  • Support for ESLint versions below 9 was dropped.

    11.0.0release notes

  • Flat configs are now the default.

    11.0.0release notes

  • Legacy configs are no longer supported.

    11.0.0release notes

  • The no-async-describe rule was renamed to no-async-suite.

    11.0.0release notes

  • The no-exports rule no longer supports CommonJS.

    11.0.0release notes

  • Support for Node.js 14, 16, and 18 was removed.

    11.0.0release notes

New APIs and options 2

Behavior and default changes 1

Tooling 1

Fixes and other changes 3

eslint-plugin-mocha 103 changes

Breaking changes 1

New APIs and options 1

Behavior and default changes 1

  • The recommended configuration turns off no-hooks-for-single-case.

    10.0.0release notes

eslint-plugin-mocha 910 changes

Breaking changes 1

New APIs and options 1

  • Added an all config preset that enables all rules.

    9.0.0release notes

Performance 7

Fixes and other changes 1

eslint-plugin-mocha 84 changes

Breaking changes 2

  • The no-skipped-tests rule no longer provides an autofix.

    8.0.0release notes

  • All rules now consistently use shared settings, which may change how existing rule configurations behave.

    8.0.0release notes

New APIs and options 2

  • The handle-done-callback rule now accepts the ignoreSkipped option.

    8.0.0release notes

  • A new no-exports rule is available.

    8.0.0release notes

eslint-plugin-mocha 72 changes

New APIs and options 1

Fixes and other changes 1

eslint-plugin-mocha 65 changes

Breaking changes 1

New APIs and options 1

  • A new rule was implemented to detect returns from async tests.

    6.0.0release notes

Behavior and default changes 1

  • The recommended ruleset was revamped, changing which rules are recommended.

    6.0.0release notes

Fixes and other changes 2

eslint-plugin-mocha 52 changes

Breaking changes 2

  • Support for ESLint versions below 4.0.0 was removed.

    5.0.0release notes

  • Support for Node.js 4, 5, and 7 was removed.

    5.0.0release notes