Skip to content

Commit

Permalink
Build with more AMD compliant wrapper
Browse files Browse the repository at this point in the history
Rebuild chai.js using an updated component that fixes an AMD wrapper
bug.
  • Loading branch information
jason0x43 committed Dec 20, 2013
1 parent 0e560c6 commit b09f754
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions chai.js
Original file line number Diff line number Diff line change
Expand Up @@ -1981,8 +1981,8 @@ module.exports = function (chai, _) {
err === desiredError
, 'expected #{this} to throw #{exp} but #{act} was thrown'
, 'expected #{this} to not throw #{exp}'
, desiredError
, err
, (desiredError instanceof Error ? desiredError.toString() : desiredError)
, (err instanceof Error ? err.toString() : err)
);

return this;
Expand All @@ -1994,7 +1994,7 @@ module.exports = function (chai, _) {
, 'expected #{this} to throw #{exp} but #{act} was thrown'
, 'expected #{this} to not throw #{exp} but #{act} was thrown'
, name
, err
, (err instanceof Error ? err.toString() : err)
);

if (!errMsg) return this;
Expand Down Expand Up @@ -2045,8 +2045,8 @@ module.exports = function (chai, _) {
thrown === true
, 'expected #{this} to throw ' + expectedThrown + actuallyGot
, 'expected #{this} to not throw ' + expectedThrown + actuallyGot
, desiredError
, thrownError
, (desiredError instanceof Error ? desiredError.toString() : desiredError)
, (thrownError instanceof Error ? thrownError.toString() : thrownError)
);
};

Expand Down Expand Up @@ -4593,6 +4593,8 @@ module.exports = function (obj) {
});




require.alias("chaijs-assertion-error/index.js", "chai/deps/assertion-error/index.js");
require.alias("chaijs-assertion-error/index.js", "chai/deps/assertion-error/index.js");
require.alias("chaijs-assertion-error/index.js", "assertion-error/index.js");
Expand All @@ -4607,7 +4609,7 @@ require.alias("chaijs-deep-eql/lib/eql.js", "chaijs-deep-eql/index.js");
require.alias("chai/index.js", "chai/index.js");if (typeof exports == "object") {
module.exports = require("chai");
} else if (typeof define == "function" && define.amd) {
define(function(){ return require("chai"); });
define([], function(){ return require("chai"); });
} else {
this["chai"] = require("chai");
}})();

0 comments on commit b09f754

Please sign in to comment.