remove accessorPropertyAttributesAreCorrect from tests

This commit is contained in:
smikes 2014-11-10 18:47:57 -07:00
parent 0d83ff2c7c
commit bb926f385d
188 changed files with 1157 additions and 195 deletions

View File

@ -43,4 +43,10 @@ verifyEnumerable(newObj, "foo1");
verifyConfigurable(newObj, "foo1");
accessorPropertyAttributesAreCorrect(newObj, "foo2", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(newObj, "foo2", getFunc());
verifyWritable(newObj, "foo2", "setVerifyHelpProp");
verifyEnumerable(newObj, "foo2");
verifyConfigurable(newObj, "foo2");

View File

@ -37,4 +37,10 @@ function getFunc2() {
Object.defineProperty(obj, "foo", {
get: getFunc2
});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc2, setFunc, "setVerifyHelpProp", false, true);
verifyEqualTo(obj, "foo", getFunc2());
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyNotEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -35,4 +35,8 @@ Object.defineProperty(obj, "foo", {
set: setFunc,
get: undefined
});
accessorPropertyAttributesAreCorrect(obj, "foo", undefined, setFunc, "setVerifyHelpProp", true, true);
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -33,4 +33,10 @@ function getFunc() {
Object.defineProperty(obj, "foo", {
get: getFunc
});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(obj, "foo", getFunc());
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -33,4 +33,8 @@ function setFunc2(value) {
Object.defineProperty(obj, "foo", {
set: setFunc2
});
accessorPropertyAttributesAreCorrect(obj, "foo", undefined, setFunc2, "setVerifyHelpProp", true, true);
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -34,4 +34,10 @@ function setFunc(value) {
Object.defineProperty(obj, "foo", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(obj, "foo", getFunc());
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -31,4 +31,8 @@ Object.defineProperty(obj, "foo", {
enumerable: false
});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, undefined, undefined, false, true);
verifyEqualTo(obj, "foo", getFunc());
verifyNotEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -34,4 +34,10 @@ Object.defineProperty(obj, "foo", {
get: getFunc,
configurable: false
});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(obj, "foo", getFunc());
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyNotEnumerable(obj, "foo");
verifyNotConfigurable(obj, "foo");

View File

@ -39,4 +39,10 @@ Object.defineProperty(obj, "foo", {
set: setFunc2,
enumerable: false
});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc2, setFunc2, "setVerifyHelpProp", false, true);
verifyEqualTo(obj, "foo", getFunc2());
verifyWritable(obj, "foo", "setVerifyHelpProp");
verifyNotEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

View File

@ -29,7 +29,11 @@ try {
configurable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, undefined, undefined, false, false);
verifyEqualTo(arrObj, "0", getFunc());
verifyNotEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e.name);

View File

@ -39,7 +39,13 @@ try {
arrObj[0] = 13;
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "helpVerifySet", false, false);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "helpVerifySet");
verifyNotEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");
} finally {
delete Array.prototype[0];
}

View File

@ -25,4 +25,8 @@ Object.defineProperty(arrObj, "0", {
configurable: true
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", true, true);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -27,4 +27,10 @@ Object.defineProperty(arrObj, "0", {
get: getFunc,
configurable: true
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "setVerifyHelpProp", false, true);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -26,4 +26,10 @@ Object.defineProperty(arrObj, "0", {
get: getFunc,
enumerable: true
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "setVerifyHelpProp", true, false);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");

View File

@ -37,4 +37,10 @@ Object.defineProperty(arrObj, "0", {
enumerable: false
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");

View File

@ -30,4 +30,10 @@ Object.defineProperty(arrObj, "0", {
});
Object.defineProperty(arrObj, "0", {});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -38,4 +38,10 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", desc);
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -32,4 +32,10 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
get: getFunc
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, setFunc, "helpVerifySet", false, false);
verifyEqualTo(arrObj, "0", getFunc());
verifyWritable(arrObj, "0", "helpVerifySet");
verifyNotEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");

View File

@ -37,4 +37,10 @@ Object.defineProperty(arrObj, "0", {
get: getFunc2
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc2, setFunc, "helpVerifySet", false, true);
verifyEqualTo(arrObj, "0", getFunc2());
verifyWritable(arrObj, "0", "helpVerifySet");
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -23,4 +23,8 @@ function setFunc(value) {
Object.defineProperty(arrObj, "0", { set: setFunc });
Object.defineProperty(arrObj, "0", { set: setFunc });
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");

View File

@ -28,4 +28,8 @@ function setFunc2(value) {
}
Object.defineProperty(arrObj, "0", { set: setFunc2 });
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc2, "setVerifyHelpProp", false, true);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -32,7 +32,11 @@ try {
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "1", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "1", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "1");
verifyNotConfigurable(arrObj, "1");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -25,4 +25,8 @@ Object.defineProperty(arrObj, "0", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", true, true);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -28,4 +28,8 @@ Object.defineProperty(arrObj, "1", {
arrObj[1] = 4;
accessorPropertyAttributesAreCorrect(arrObj, "1", getFunc, undefined, undefined, false, true);
verifyEqualTo(arrObj, "1", getFunc());
verifyNotEnumerable(arrObj, "1");
verifyConfigurable(arrObj, "1");

View File

@ -29,7 +29,11 @@ Object.defineProperty(arrObj, "1", {
try {
arrObj[1] = 4;
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "1", getFunc, undefined, undefined, false, true);
verifyEqualTo(arrObj, "1", getFunc());
verifyNotEnumerable(arrObj, "1");
verifyConfigurable(arrObj, "1");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -32,7 +32,11 @@ try {
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "1", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "1", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "1");
verifyNotConfigurable(arrObj, "1");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -31,7 +31,11 @@ try {
set: function () { }
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "1", getFunc, undefined, undefined, false, false);
verifyEqualTo(arrObj, "1", getFunc());
verifyNotEnumerable(arrObj, "1");
verifyNotConfigurable(arrObj, "1");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -31,4 +31,8 @@ Object.defineProperty(arrObj, "1", {
get: undefined
});
accessorPropertyAttributesAreCorrect(arrObj, "1", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "1", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "1");
verifyNotConfigurable(arrObj, "1");

View File

@ -29,4 +29,8 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
get: getFunc
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, undefined, undefined, false, true);
verifyEqualTo(arrObj, "0", getFunc());
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -28,4 +28,6 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
get: undefined
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, undefined, undefined, false, true);
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -28,4 +28,8 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
get: getFunc
});
accessorPropertyAttributesAreCorrect(arrObj, "0", getFunc, undefined, undefined, false, true);
verifyEqualTo(arrObj, "0", getFunc());
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -28,4 +28,8 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", false, true);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -25,4 +25,6 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
set: undefined
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, undefined, undefined, false, true);
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -29,4 +29,8 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", false, true);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -30,4 +30,8 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
enumerable: false
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", false, true);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyConfigurable(arrObj, "0");

View File

@ -28,4 +28,8 @@ Object.defineProperty(arrObj, "0", {
Object.defineProperty(arrObj, "0", {
configurable: false
});
accessorPropertyAttributesAreCorrect(arrObj, "0", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "0", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "0");
verifyNotConfigurable(arrObj, "0");

View File

@ -37,4 +37,10 @@ Object.defineProperty(arrObj, "1", {
enumerable: false,
configurable: false
});
accessorPropertyAttributesAreCorrect(arrObj, "1", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(arrObj, "1", getFunc());
verifyWritable(arrObj, "1", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "1");
verifyNotConfigurable(arrObj, "1");

View File

@ -30,4 +30,10 @@ Object.defineProperty(arrObj, "property", {
configurable: true
});
accessorPropertyAttributesAreCorrect(arrObj, "property", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(arrObj, "property", getFunc());
verifyWritable(arrObj, "property", "setVerifyHelpProp");
verifyEnumerable(arrObj, "property");
verifyConfigurable(arrObj, "property");

View File

@ -36,4 +36,10 @@ Object.defineProperty(arrObj, "property", {
configurable: false
});
accessorPropertyAttributesAreCorrect(arrObj, "property", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(arrObj, "property", getFunc());
verifyWritable(arrObj, "property", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "property");
verifyNotConfigurable(arrObj, "property");

View File

@ -34,7 +34,13 @@ try {
}
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "property", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(arrObj, "property", getFunc());
verifyWritable(arrObj, "property", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "property");
verifyNotConfigurable(arrObj, "property");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -28,7 +28,11 @@ try {
set: function () {}
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "property", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "property", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "property");
verifyNotConfigurable(arrObj, "property");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -29,7 +29,11 @@ try {
enumerable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "property", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "property", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "property");
verifyNotConfigurable(arrObj, "property");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -29,7 +29,11 @@ try {
configurable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arrObj, "property", undefined, setFunc, "setVerifyHelpProp", false, false);
verifyWritable(arrObj, "property", "setVerifyHelpProp");
verifyNotEnumerable(arrObj, "property");
verifyNotConfigurable(arrObj, "property");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -34,5 +34,11 @@ includes: [propertyHelper.js]
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(arguments, "0", getFunc());
verifyWritable(arguments, "0", "setVerifyHelpProp");
verifyEnumerable(arguments, "0");
verifyConfigurable(arguments, "0");
}(0, 1, 2));

View File

@ -28,5 +28,11 @@ includes: [propertyHelper.js]
enumerable: true,
configurable: true
});
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, setFunc, "setVerifyHelpProp", true, true);
verifyEqualTo(arguments, "0", getFunc());
verifyWritable(arguments, "0", "setVerifyHelpProp");
verifyEnumerable(arguments, "0");
verifyConfigurable(arguments, "0");
}(0, 1, 2));

View File

@ -36,5 +36,9 @@ includes: [propertyHelper.js]
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc2, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc2());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
}(0, 1, 2));

View File

@ -31,5 +31,9 @@ includes: [propertyHelper.js]
enumerable: false,
configurable: false
});
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc2, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc2());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
}(0, 1, 2));

View File

@ -37,7 +37,11 @@ includes: [propertyHelper.js]
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc1, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc1());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -31,7 +31,11 @@ includes: [propertyHelper.js]
get: getFunc2
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc1, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc1());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -38,7 +38,11 @@ includes: [propertyHelper.js]
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -32,7 +32,11 @@ includes: [propertyHelper.js]
set: setFunc
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -33,7 +33,11 @@ includes: [propertyHelper.js]
if (a !== 0) {
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, true, false);
verifyEqualTo(arguments, "0", getFunc());
verifyEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -28,7 +28,11 @@ includes: [propertyHelper.js]
enumerable: false
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, true, false);
verifyEqualTo(arguments, "0", getFunc());
verifyEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -33,7 +33,11 @@ includes: [propertyHelper.js]
if (a !== 0) {
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, true, false);
verifyEqualTo(arguments, "0", getFunc());
verifyEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -28,7 +28,11 @@ includes: [propertyHelper.js]
configurable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, true, false);
verifyEqualTo(arguments, "0", getFunc());
verifyEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -33,5 +33,11 @@ includes: [propertyHelper.js]
if (a !== 0) {
$ERROR('Expected a === 0, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(arguments, "0", getFunc());
verifyWritable(arguments, "0", "setVerifyHelpProp");
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
}(0, 1, 2));

View File

@ -29,5 +29,11 @@ includes: [propertyHelper.js]
enumerable: false,
configurable: false
});
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(arguments, "0", getFunc());
verifyWritable(arguments, "0", "setVerifyHelpProp");
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
}(0, 1, 2));

View File

@ -32,5 +32,9 @@ includes: [propertyHelper.js]
enumerable: false,
configurable: false
});
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc2, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc2());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
}());

View File

@ -32,7 +32,11 @@ includes: [propertyHelper.js]
get: getFunc2
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc1, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc1());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -33,7 +33,11 @@ includes: [propertyHelper.js]
set: setFunc
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, false, false);
verifyEqualTo(arguments, "0", getFunc());
verifyNotEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -29,7 +29,11 @@ includes: [propertyHelper.js]
enumerable: false
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, true, false);
verifyEqualTo(arguments, "0", getFunc());
verifyEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -28,7 +28,11 @@ includes: [propertyHelper.js]
configurable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "0", getFunc, undefined, undefined, true, false);
verifyEqualTo(arguments, "0", getFunc());
verifyEnumerable(arguments, "0");
verifyNotConfigurable(arguments, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -27,5 +27,11 @@ includes: [propertyHelper.js]
enumerable: true,
configurable: true
});
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", getFunc, setFunc, "testgetFunction", true, true);
verifyEqualTo(arguments, "genericProperty", getFunc());
verifyWritable(arguments, "genericProperty", "testgetFunction");
verifyEnumerable(arguments, "genericProperty");
verifyConfigurable(arguments, "genericProperty");
}(1, 2, 3));

View File

@ -27,5 +27,11 @@ includes: [propertyHelper.js]
enumerable: true,
configurable: true
});
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", getFunc, setFunc, "testgetFunction", true, true);
verifyEqualTo(arguments, "genericProperty", getFunc());
verifyWritable(arguments, "genericProperty", "testgetFunction");
verifyEnumerable(arguments, "genericProperty");
verifyConfigurable(arguments, "genericProperty");
}(1, 2, 3));

View File

@ -41,5 +41,11 @@ includes: [propertyHelper.js]
$ERROR('Expected c === 3, actually ' + c);
}
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", getFunc, setFunc, "testgetFunction", false, false);
verifyEqualTo(arguments, "genericProperty", getFunc());
verifyWritable(arguments, "genericProperty", "testgetFunction");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
}(1, 2, 3));

View File

@ -37,5 +37,11 @@ includes: [propertyHelper.js]
enumerable: false,
configurable: false
});
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", getFunc, setFunc, "testgetFunction", false, false);
verifyEqualTo(arguments, "genericProperty", getFunc());
verifyWritable(arguments, "genericProperty", "testgetFunction");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
}(1, 2, 3));

View File

@ -38,7 +38,13 @@ includes: [propertyHelper.js]
$ERROR('Expected a === 1, actually ' + a);
}
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", getFunc, setFunc, "helpVerifyGet", false, false, false)
verifyEqualTo(arguments, "genericProperty", getFunc());
verifyWritable(arguments, "genericProperty", "helpVerifyGet");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -33,7 +33,13 @@ includes: [propertyHelper.js]
}
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", getFunc, setFunc, "helpVerifyGet", false, false, false);
verifyEqualTo(arguments, "genericProperty", getFunc());
verifyWritable(arguments, "genericProperty", "helpVerifyGet");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -30,7 +30,11 @@ includes: [propertyHelper.js]
}
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", undefined, setFunc, "genericPropertyString", false, false, false);
verifyWritable(arguments, "genericProperty", "genericPropertyString");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -29,7 +29,11 @@ includes: [propertyHelper.js]
}
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", undefined, setFunc, "genericPropertyString", false, false, false);
verifyWritable(arguments, "genericProperty", "genericPropertyString");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -32,7 +32,11 @@ includes: [propertyHelper.js]
if (c !== 3) {
$ERROR('Expected c === 3, actually ' + c);
}
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", undefined, setFunc, "genericPropertyString", true, false);
verifyWritable(arguments, "genericProperty", "genericPropertyString");
verifyEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -28,7 +28,11 @@ includes: [propertyHelper.js]
enumerable: false
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", undefined, setFunc, "genericPropertyString", true, false);
verifyWritable(arguments, "genericProperty", "genericPropertyString");
verifyEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -28,7 +28,11 @@ includes: [propertyHelper.js]
configurable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", undefined, setFunc, "genericPropertyString", false, false, false);
verifyWritable(arguments, "genericProperty", "genericPropertyString");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -27,7 +27,11 @@ includes: [propertyHelper.js]
configurable: true
});
} catch (e) {
accessorPropertyAttributesAreCorrect(arguments, "genericProperty", undefined, setFunc, "genericPropertyString", false, false, false);
verifyWritable(arguments, "genericProperty", "genericPropertyString");
verifyNotEnumerable(arguments, "genericProperty");
verifyNotConfigurable(arguments, "genericProperty");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -43,8 +43,12 @@ try {
$ERROR("Expected desc2 to be as configured.");
}
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, undefined, undefined,
true, true);
verifyEqualTo(obj, "0", getFunc());
verifyEnumerable(obj, "0");
verifyConfigurable(obj, "0");
} finally {
delete obj[0];
}

View File

@ -24,4 +24,8 @@ Object.defineProperty(obj, "property", {
configurable: true
});
accessorPropertyAttributesAreCorrect(obj, "property", undefined, setFunc, "setVerifyHelpProp", true, true);
verifyWritable(obj, "property", "setVerifyHelpProp");
verifyEnumerable(obj, "property");
verifyConfigurable(obj, "property");

View File

@ -39,4 +39,10 @@ Object.defineProperty(obj, "property", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction1");
verifyNotEnumerable(obj, "property");
verifyConfigurable(obj, "property");

View File

@ -41,4 +41,10 @@ Object.defineProperty(obj, "0", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction1");
verifyNotEnumerable(obj, "0");
verifyConfigurable(obj, "0");

View File

@ -40,4 +40,10 @@ Object.defineProperty(obj, "prop", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "prop", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "prop", getFunc());
verifyWritable(obj, "prop", "verifySetFunction1");
verifyNotEnumerable(obj, "prop");
verifyConfigurable(obj, "prop");

View File

@ -42,4 +42,10 @@ Object.defineProperty(obj, "0", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction1");
verifyNotEnumerable(obj, "0");
verifyConfigurable(obj, "0");

View File

@ -41,7 +41,13 @@ try {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction1");
verifyNotEnumerable(obj, "0");
verifyConfigurable(obj, "0");
} finally {
delete obj[0];
delete obj.verifySetFunction;

View File

@ -41,4 +41,10 @@ Object.defineProperty(obj, "0", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction1");
verifyNotEnumerable(obj, "0");
verifyConfigurable(obj, "0");

View File

@ -42,4 +42,10 @@ Object.defineProperty(obj, "property", {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction1");
verifyNotEnumerable(obj, "property");
verifyConfigurable(obj, "property");

View File

@ -40,7 +40,13 @@ try {
set: setFunc
});
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction1", false, true);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction1");
verifyNotEnumerable(obj, "property");
verifyConfigurable(obj, "property");
} finally {
delete obj.property;
delete obj.verifySetFunction;

View File

@ -38,7 +38,13 @@ try {
});
} catch (e) {
result = e instanceof TypeError;
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction");
verifyNotEnumerable(obj, "property");
verifyNotConfigurable(obj, "property");
}
try {
@ -52,7 +58,13 @@ try {
$ERROR('Expected result to be true, actually ' + result);
}
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction");
verifyNotEnumerable(obj, "property");
verifyNotConfigurable(obj, "property");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -38,7 +38,13 @@ try {
});
} catch (e) {
result = e instanceof TypeError;
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction");
verifyNotEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
}
try {
@ -52,7 +58,13 @@ try {
$ERROR('Expected result to be true, actually ' + result );
}
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction");
verifyNotEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -39,7 +39,13 @@ try {
});
} catch (e) {
result = e instanceof TypeError;
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction");
verifyNotEnumerable(obj, "property");
verifyNotConfigurable(obj, "property");
}
try {
@ -54,7 +60,13 @@ try {
$ERROR('Expected result to be true, actually ' + result);
}
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "verifySetFunction");
verifyNotEnumerable(obj, "property");
verifyNotConfigurable(obj, "property");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -39,7 +39,13 @@ try {
} catch (e) {
result = e instanceof TypeError;
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction");
verifyNotEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
}
try {
@ -53,7 +59,13 @@ try {
$ERROR('Expected result to be true, actually ' + result);
}
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction");
verifyNotEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
if (!(e instanceof TypeError)) {

View File

@ -38,7 +38,13 @@ try {
});
} catch (e) {
result = e instanceof TypeError;
accessorPropertyAttributesAreCorrect(obj, "prop", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "prop", getFunc());
verifyWritable(obj, "prop", "verifySetFunction");
verifyNotEnumerable(obj, "prop");
verifyNotConfigurable(obj, "prop");
}
try {
@ -53,7 +59,13 @@ try {
}
accessorPropertyAttributesAreCorrect(obj, "prop", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "prop", getFunc());
verifyWritable(obj, "prop", "verifySetFunction");
verifyNotEnumerable(obj, "prop");
verifyNotConfigurable(obj, "prop");
if (!(e1 instanceof TypeError)) {

View File

@ -40,7 +40,13 @@ try {
});
} catch (e) {
result = e instanceof TypeError;
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction");
verifyNotEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
}
try {
@ -54,7 +60,13 @@ try {
$ERROR('Expected result to be true, actually ' + result );
}
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunction", false, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunction");
verifyNotEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -49,7 +49,13 @@ try {
}
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunc", true, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunc");
verifyEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
if (!(e instanceof TypeError)) {

View File

@ -51,7 +51,13 @@ try {
}
accessorPropertyAttributesAreCorrect(obj, "prop", getFunc, setFunc, "verifySetFunc", true, false);
verifyEqualTo(obj, "prop", getFunc());
verifyWritable(obj, "prop", "verifySetFunc");
verifyEnumerable(obj, "prop");
verifyNotConfigurable(obj, "prop");
if (!(e instanceof TypeError)) {

View File

@ -49,7 +49,13 @@ try {
}
accessorPropertyAttributesAreCorrect(obj, "prop", getFunc, setFunc, "verifySetFunc", true, false);
verifyEqualTo(obj, "prop", getFunc());
verifyWritable(obj, "prop", "verifySetFunc");
verifyEnumerable(obj, "prop");
verifyNotConfigurable(obj, "prop");
if (!(e instanceof TypeError)) {
$ERROR("Expected TypeError, got " + e);

View File

@ -49,7 +49,13 @@ try {
$ERROR('Expected !desc2.hasOwnProperty("value") to be true, actually ' + !desc2.hasOwnProperty("value"));
}
accessorPropertyAttributesAreCorrect(obj, "0", getFunc, setFunc, "verifySetFunc", true, false);
verifyEqualTo(obj, "0", getFunc());
verifyWritable(obj, "0", "verifySetFunc");
verifyEnumerable(obj, "0");
verifyNotConfigurable(obj, "0");
if (!(e instanceof TypeError)) {

View File

@ -27,4 +27,10 @@ Object.defineProperty(obj, "property", {
get: getFunc,
configurable: true
});
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "setVerifyHelpProp", false, true);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "setVerifyHelpProp");
verifyNotEnumerable(obj, "property");
verifyConfigurable(obj, "property");

View File

@ -26,4 +26,10 @@ Object.defineProperty(obj, "property", {
get: getFunc,
enumerable: true
});
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "setVerifyHelpProp", true, false);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "setVerifyHelpProp");
verifyEnumerable(obj, "property");
verifyNotConfigurable(obj, "property");

View File

@ -36,4 +36,10 @@ Object.defineProperty(obj, "property", {
enumerable: false
});
accessorPropertyAttributesAreCorrect(obj, "property", getFunc, setFunc, "setVerifyHelpProp", false, false);
verifyEqualTo(obj, "property", getFunc());
verifyWritable(obj, "property", "setVerifyHelpProp");
verifyNotEnumerable(obj, "property");
verifyNotConfigurable(obj, "property");

View File

@ -28,4 +28,10 @@ Object.defineProperty(obj, "foo", {
});
Object.defineProperty(obj, "foo", {});
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, setFunc, "helpVerifySet", false, false);
verifyEqualTo(obj, "foo", getFunc());
verifyWritable(obj, "foo", "helpVerifySet");
verifyNotEnumerable(obj, "foo");
verifyNotConfigurable(obj, "foo");

View File

@ -28,4 +28,10 @@ Object.defineProperty(obj, "foo", {
});
Object.defineProperty(obj, "foo", { get: getFunc });
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, setFunc, "helpVerifySet", false, false);
verifyEqualTo(obj, "foo", getFunc());
verifyWritable(obj, "foo", "helpVerifySet");
verifyNotEnumerable(obj, "foo");
verifyNotConfigurable(obj, "foo");

View File

@ -33,4 +33,10 @@ function getFunc2() {
}
Object.defineProperty(obj, "foo", { get: getFunc2 });
accessorPropertyAttributesAreCorrect(obj, "foo", getFunc2, setFunc1, "helpVerifySet", false, true);
verifyEqualTo(obj, "foo", getFunc2());
verifyWritable(obj, "foo", "helpVerifySet");
verifyNotEnumerable(obj, "foo");
verifyConfigurable(obj, "foo");

Some files were not shown because too many files have changed in this diff Show More