F.attach()
FuncUnit.attach
attach(runner)
Attach a test runner, either QUnit, Mocha, or Jasmine to FuncUnit which will be used to pause, resume, and make assertions.
var QUnit = require("qunit");
F.attach(QUnit);
Parameters
-
runner
{Object}
A test runner to attach to FuncUnit.
Use
By default FuncUnit does not control the test runner or make assertions. This is left up to you. So for example if you're using QUnit you might write a test like:
You can prevent this extra boilerplate by attaching a test runner.
F.attach()
works with QUnit, Jasmine, and Mocha.