diff options
Diffstat (limited to 'testLib/sharedTestCases.js')
-rw-r--r-- | testLib/sharedTestCases.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/testLib/sharedTestCases.js b/testLib/sharedTestCases.js index b6caf6a..941b971 100644 --- a/testLib/sharedTestCases.js +++ b/testLib/sharedTestCases.js @@ -390,4 +390,17 @@ module.exports = function () { expect(constModule.dirname).to.equal(require("./constModule").dirname); }); + it("should be possible to create a class", function() { + var BClass = rewire("./ClassB"); + + expect(function() { + new BClass(); + }).to.not.throw; + + var b = new BClass(); + + expect(b.prop1).to.equal("B"); + expect(b.prop2).to.equal("something") + }); + }; |