QUnit API Documentation

Category: Callbacks


When integrating QUnit into other tools like CI servers, use these callbacks as an API to read test results.

QUnit bundles two addons that both use these callbacks: The JUnit logger and the PhantomJS runner.

QUnit.begin()

Register a callback to fire whenever the test suite begins.

QUnit.done()

Register a callback to fire whenever the test suite ends.

QUnit.log()

Register a callback to fire whenever an assertion completes.

QUnit.moduleDone()

Register a callback to fire whenever a module ends.

QUnit.moduleStart()

Register a callback to fire whenever a module begins.

QUnit.testDone()

Register a callback to fire whenever a test ends.

QUnit.testStart()

Register a callback to fire whenever a test begins.

gipoco.com is neither affiliated with the authors of this page nor responsible for its contents. This is a safe-cache copy of the original web site.