diff --git a/lib/should.js b/lib/should.js index 9df14dc..8559a49 100644 --- a/lib/should.js +++ b/lib/should.js @@ -78,7 +78,7 @@ exports.not.exist = function(obj, msg){ Object.defineProperty(Object.prototype, 'should', { set: function(){}, get: function(){ - return new Assertion(this); + return new Assertion(Object(this).valueOf()); }, configurable: true }); diff --git a/package.json b/package.json index 60a8400..5ee6b6d 100644 --- a/package.json +++ b/package.json @@ -5,9 +5,8 @@ , "contributors": [ "Aseem Kishore " ] , "devDependencies": { "mocha": "*" - , "should": "*" } , "keywords": ["test", "bdd", "assert"] , "main": "./lib/should.js" , "engines": { "node": ">= 0.2.0" } -} \ No newline at end of file +} diff --git a/test/should.test.js b/test/should.test.js index 8dd2790..4afc21d 100644 --- a/test/should.test.js +++ b/test/should.test.js @@ -21,7 +21,7 @@ module.exports = { }, 'test double require': function(){ - require('should').should.equal(should); + require('../').should.equal(should); }, 'test assertion': function(){