Files
iD/test/spec/spec_helpers.js
John Firebaugh e95d163dbc Apply tag classes to vertices and points
While here, introduce a `classed` matcher for Chai.
2013-01-11 12:22:23 -08:00

13 lines
357 B
JavaScript

chai.use(function (chai, utils) {
var flag = utils.flag;
chai.Assertion.addMethod('classed', function (className) {
this.assert(
flag(this, 'object').classed(className)
, 'expected #{this} to be classed #{exp}'
, 'expected #{this} not to be classed #{exp}'
, className
);
});
});