Files
hudozka/node_modules/should/lib/ext/chain.js
T
2014-02-12 12:36:59 +04:00

18 lines
377 B
JavaScript

/*!
* Should
* Copyright(c) 2010-2014 TJ Holowaychuk <tj@vision-media.ca>
* MIT Licensed
*/
module.exports = function(should, Assertion) {
function addLink(name) {
Object.defineProperty(Assertion.prototype, name, {
get: function() {
return this;
}
});
}
['an', 'of', 'a', 'and', 'be', 'have', 'with', 'is', 'which'].forEach(addLink);
};