Skip to content

Editor Plugins

The following editor-related packages are available:

TextMate

The Mocha TextMate bundle includes snippets to make writing tests quicker and more enjoyable.

JetBrains

JetBrains provides a NodeJS plugin for its suite of IDEs (IntelliJ IDEA, WebStorm, etc.), which contains a Mocha test runner, among other things.

JetBrains Mocha Runner Plugin in Action

The plugin is titled NodeJS, and can be installed via Preferences > Plugins, assuming your license allows it.

Wallaby.js

Wallaby.js is a continuous testing tool that enables real-time code coverage for Mocha with any assertion library in VS Code, Atom, JetBrains IDEs (IntelliJ IDEA, WebStorm, etc.), Sublime Text and Visual Studio for both browser and node.js projects.

Wallaby.js in Action

Emacs

Emacs support for running Mocha tests is available via a 3rd party package mocha.el. The package is available on MELPA, and can be installed via M-x package-install mocha.

Emacs Mocha Runner in Action

Mocha Sidebar (VS Code)

Mocha sidebar is the most complete mocha extension for vs code.

Features

  • see all tests in VS Code sidebar menu
  • run & debug tests for each level hierarchy from all tests to a single test (and each suite)
  • auto run tests on file save
  • see tests results directly in the code editor

mocha side bar in Action