Plugins
API Extensions
These plugins provide custom assertions or a complete new interface to use QUnit.
- SpecIt A QUnit-based API for bdd-style testing
- Pavlov - extends QUnit with a rich, higher-level, Behavioral API
- Parameterize - A QUnit plugin For Running Parameterized Tests
- HTML - A QUnit plugin for assertion methods to compare two HTML strings for equality after a rigorous normalization process.
- Step - A QUnit plugin for asserting the proper sequence in which the code should execute.
- Close - A QUnit plugin for asserting that a number is approximately equal (or not) to an expected number, within a given tolerance.
- Canvas - A QUnit plugin for asserting individual pixel values within a Canvas element.
- qunit-promises - A QUnit plugin for asserting results of promises.
- qunit-once - A QUnit plugin that adds
setupOnce
andteardownOnce
to module's config. - qunit-inject - A QUnit plugin that allows dependency injection from a module's config object into individual unit tests
- qunit-helpful - A QUnit plugin that shows the failed expression in assertion message.
- Classes - A QUnit plugin for asserting if an element has, or lacks, any number of classes.
- Compare - A QUnit plugin for asserting numerical comparisons like greater than, less than, etc.
Mocking Tools
These libraries can be used along with QUnit to mock Ajax requests, timers and more.
- jQuery-Mockjax - Interface to mock ajax requests and responses
- Sinon.js integration with QUnit
- DexterJS - a test helper to mock functions and the XHR object.
Integration
These plugins make it easier to integrate QUnit in various testing setups.
- QUnit PhantomJS Runner - A PhantomJS-powered headless test runner, providing basic console output for QUnit tests.
- Composite - bundle multiple test suites into a single file, running them in an
br
- JUnit Reporter - produces JUnit-style XML output for test results, for integration into tools like Jenkins
- Rails plugin for QUnit integration
- QUnit testrunner plugin for JsTestDriver
- Drupal module for QUnit
- QUnit Extras - Extends QUnit with extra features and CLI support
Themes
Alternative themes for the HTML Reporter. Load their CSS file instead of the default one.
- QUnit NV Theme
- QUnit Ninja Theme
- QUnit Gabe Theme
- QUnit Burce Theme