- * QUnit 1.2.0pre - A JavaScript Unit Testing Framework
+ * QUnit v1.2.0 - A JavaScript Unit Testing Framework
*
* http://docs.jquery.com/QUnit
*
*
* http://docs.jquery.com/QUnit
*
- * QUnit 1.2.0pre - A JavaScript Unit Testing Framework
+ * QUnit v1.2.0 - A JavaScript Unit Testing Framework
*
* http://docs.jquery.com/QUnit
*
*
* http://docs.jquery.com/QUnit
*
+ var getProto = Object.getPrototypeOf || function (obj) {
+ return obj.__proto__;
+ };
+
var callbacks = function () {
// for string, boolean, number and null
var callbacks = function () {
// for string, boolean, number and null
// comparing constructors is more strict than using
// instanceof
if (a.constructor !== b.constructor) {
// comparing constructors is more strict than using
// instanceof
if (a.constructor !== b.constructor) {
+ // Allow objects with no prototype to be equivalent to
+ // objects with Object as their constructor.
+ if (!((getProto(a) === null && getProto(b) === Object.prototype) ||
+ (getProto(b) === null && getProto(a) === Object.prototype)))
+ {
+ return false;
+ }
}
// stack constructor before traversing properties
}
// stack constructor before traversing properties