mirror of
https://github.com/tc39/test262.git
synced 2025-07-26 23:44:27 +02:00
Re-generate tests
This commit is contained in:
parent
31f7b3e218
commit
7630235d5d
@ -37,7 +37,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");{ function f() { } }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});{ function f() { } }'
|
||||||
);
|
);
|
||||||
|
@ -21,8 +21,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
{ function f() { } }'
|
configurable: true\
|
||||||
|
});{ function f() { } }'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (true) function f() { } else function _f() {}'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (true) function f() { } else function _f() {}'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (true) function f() { } else function _f() {}'
|
configurable: true\
|
||||||
|
});if (true) function f() { } else function _f() {}'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (false) function _f() {} else function f() { }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (false) function _f() {} else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (false) function _f() {} else function f() { }'
|
configurable: true\
|
||||||
|
});if (false) function _f() {} else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (true) function f() { } else ;'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (true) function f() { } else ;'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (true) function f() { } else ;'
|
configurable: true\
|
||||||
|
});if (true) function f() { } else ;'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (true) function f() { }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (true) function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (true) function f() { }'
|
configurable: true\
|
||||||
|
});if (true) function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (false) ; else function f() { }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (false) ; else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (false) ; else function f() { }'
|
configurable: true\
|
||||||
|
});if (false) ; else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -37,9 +37,11 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");switch (1) {' +
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});switch (1) {' +
|
||||||
' case 1:' +
|
' case 1:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -21,10 +21,11 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
switch (1) {' +
|
configurable: true\
|
||||||
|
});switch (1) {' +
|
||||||
' case 1:' +
|
' case 1:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -37,9 +37,11 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");switch (1) {' +
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});switch (1) {' +
|
||||||
' default:' +
|
' default:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -21,10 +21,11 @@ eval(
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
switch (1) {' +
|
configurable: true\
|
||||||
|
});switch (1) {' +
|
||||||
' default:' +
|
' default:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -37,7 +37,9 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");{ function f() { } }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});{ function f() { } }'
|
||||||
);
|
);
|
||||||
|
@ -21,8 +21,9 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
{ function f() { } }'
|
configurable: true\
|
||||||
|
});{ function f() { } }'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (true) function f() { } else function _f() {}'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (true) function f() { } else function _f() {}'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (true) function f() { } else function _f() {}'
|
configurable: true\
|
||||||
|
});if (true) function f() { } else function _f() {}'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (false) function _f() {} else function f() { }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (false) function _f() {} else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (false) function _f() {} else function f() { }'
|
configurable: true\
|
||||||
|
});if (false) function _f() {} else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (true) function f() { } else ;'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (true) function f() { } else ;'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (true) function f() { } else ;'
|
configurable: true\
|
||||||
|
});if (true) function f() { } else ;'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (true) function f() { }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (true) function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (true) function f() { }'
|
configurable: true\
|
||||||
|
});if (true) function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -46,7 +46,9 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");if (false) ; else function f() { }'
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});if (false) ; else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -30,8 +30,9 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
if (false) ; else function f() { }'
|
configurable: true\
|
||||||
|
});if (false) ; else function f() { }'
|
||||||
);
|
);
|
||||||
|
@ -37,9 +37,11 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");switch (1) {' +
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});switch (1) {' +
|
||||||
' case 1:' +
|
' case 1:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -21,10 +21,11 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
switch (1) {' +
|
configurable: true\
|
||||||
|
});switch (1) {' +
|
||||||
' case 1:' +
|
' case 1:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -37,9 +37,11 @@ Object.defineProperty(fnGlobalObject(), 'f', {
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyNotConfigurable(global, "f");switch (1) {' +
|
writable: true,\
|
||||||
|
configurable: false\
|
||||||
|
});switch (1) {' +
|
||||||
' default:' +
|
' default:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -21,10 +21,11 @@ info: |
|
|||||||
'var global = fnGlobalObject();\
|
'var global = fnGlobalObject();\
|
||||||
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
assert.sameValue(f, undefined, "binding is initialized to `undefined`");\
|
||||||
\
|
\
|
||||||
verifyEnumerable(global, "f");\
|
verifyProperty(global, "f", {\
|
||||||
verifyWritable(global, "f");\
|
enumerable: true,\
|
||||||
verifyConfigurable(global, "f");\
|
writable: true,\
|
||||||
switch (1) {' +
|
configurable: true\
|
||||||
|
});switch (1) {' +
|
||||||
' default:' +
|
' default:' +
|
||||||
' function f() { }' +
|
' function f() { }' +
|
||||||
'}\
|
'}\
|
||||||
|
@ -20,9 +20,11 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
{
|
{
|
||||||
function f() { }
|
function f() { }
|
||||||
|
@ -29,8 +29,10 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
if (true) function f() { } else function _f() {}
|
if (true) function f() { } else function _f() {}
|
||||||
|
@ -29,8 +29,10 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
if (false) function _f() {} else function f() { }
|
if (false) function _f() {} else function f() { }
|
||||||
|
@ -29,8 +29,10 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
if (true) function f() { } else ;
|
if (true) function f() { } else ;
|
||||||
|
@ -29,8 +29,10 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
if (true) function f() { }
|
if (true) function f() { }
|
||||||
|
@ -29,8 +29,10 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
if (false) ; else function f() { }
|
if (false) ; else function f() { }
|
||||||
|
@ -20,9 +20,11 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
switch (1) {
|
switch (1) {
|
||||||
case 1:
|
case 1:
|
||||||
|
@ -20,9 +20,11 @@ info: |
|
|||||||
var global = fnGlobalObject();
|
var global = fnGlobalObject();
|
||||||
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
assert.sameValue(f, undefined, 'binding is initialized to `undefined`');
|
||||||
|
|
||||||
verifyEnumerable(global, 'f');
|
verifyProperty(global, "f", {
|
||||||
verifyWritable(global, 'f');
|
enumerable: true,
|
||||||
verifyNotConfigurable(global, 'f');
|
writable: true,
|
||||||
|
configurable: false
|
||||||
|
});
|
||||||
|
|
||||||
switch (1) {
|
switch (1) {
|
||||||
default:
|
default:
|
||||||
|
@ -40,27 +40,35 @@ let o = {c: 3, d: 4};
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
|
|
||||||
(function(obj) {
|
(function(obj) {
|
||||||
assert.sameValue(obj.a, 1);
|
|
||||||
assert.sameValue(obj.b, 2);
|
|
||||||
assert.sameValue(obj.c, 3);
|
|
||||||
assert.sameValue(obj.d, 4);
|
|
||||||
assert.sameValue(Object.keys(obj).length, 4);
|
assert.sameValue(Object.keys(obj).length, 4);
|
||||||
|
|
||||||
verifyEnumerable(obj, "a");
|
verifyProperty(obj, "a", {
|
||||||
verifyWritable(obj, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 1
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "b");
|
verifyProperty(obj, "b", {
|
||||||
verifyWritable(obj, "b");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "b");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "c");
|
verifyProperty(obj, "c", {
|
||||||
verifyWritable(obj, "c");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "c");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 3
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "d");
|
verifyProperty(obj, "d", {
|
||||||
verifyWritable(obj, "d");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "d");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}.apply(null, [{a: 1, b: 2, ...o}]));
|
}.apply(null, [{a: 1, b: 2, ...o}]));
|
||||||
|
|
||||||
|
@ -44,14 +44,16 @@ let o = {
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
|
|
||||||
(function(obj) {
|
(function(obj) {
|
||||||
assert.sameValue(Object.getOwnPropertyDescriptor(obj, "a").value, 42);
|
|
||||||
assert.sameValue(obj.c, 4);
|
assert.sameValue(obj.c, 4);
|
||||||
assert.sameValue(obj.d, 5);
|
assert.sameValue(obj.d, 5);
|
||||||
assert.sameValue(Object.keys(obj).length, 3);
|
assert.sameValue(Object.keys(obj).length, 3);
|
||||||
|
|
||||||
verifyEnumerable(obj, "a");
|
verifyProperty(obj, "a", {
|
||||||
verifyWritable(obj, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 42
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}.apply(null, [{...o, c: 4, d: 5}]));
|
}.apply(null, [{...o, c: 4, d: 5}]));
|
||||||
|
|
||||||
|
@ -34,14 +34,19 @@ var callCount = 0;
|
|||||||
assert.sameValue(obj.a, 3)
|
assert.sameValue(obj.a, 3)
|
||||||
assert.sameValue(obj.b, 2);
|
assert.sameValue(obj.b, 2);
|
||||||
|
|
||||||
verifyEnumerable(obj, "a");
|
verifyProperty(obj, "a", {
|
||||||
verifyWritable(obj, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(obj, "b");
|
value: 3
|
||||||
verifyWritable(obj, "b");
|
});
|
||||||
verifyConfigurable(obj, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(obj, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}.apply(null, [{...o, a: 3}]));
|
}.apply(null, [{...o, a: 3}]));
|
||||||
|
|
||||||
|
@ -40,17 +40,21 @@ let o = {c: 3, d: 4};
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
|
|
||||||
(function(obj) {
|
(function(obj) {
|
||||||
assert.sameValue(obj.c, 3);
|
|
||||||
assert.sameValue(obj.d, 4);
|
|
||||||
assert.sameValue(Object.keys(obj).length, 2);
|
assert.sameValue(Object.keys(obj).length, 2);
|
||||||
|
|
||||||
verifyEnumerable(obj, "c");
|
verifyProperty(obj, "c", {
|
||||||
verifyWritable(obj, "c");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "c");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 3
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "d");
|
verifyProperty(obj, "d", {
|
||||||
verifyWritable(obj, "d");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "d");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}.apply(null, [{...o}]));
|
}.apply(null, [{...o}]));
|
||||||
|
|
||||||
|
@ -43,13 +43,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = ({...x} = { get v() { count++; return 2; } }) => {
|
f = ({...x} = { get v() { count++; return 2; } }) => {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -44,18 +44,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = ({...rest} = o) => {
|
f = ({...rest} = o) => {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -42,19 +42,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = ({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) => {
|
f = ({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) => {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -43,13 +43,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = ({...x}) => {
|
f = ({...x}) => {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -44,18 +44,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = ({...rest}) => {
|
f = ({...rest}) => {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -42,19 +42,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = ({a, b, ...rest}) => {
|
f = ({a, b, ...rest}) => {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -34,9 +34,11 @@ var vals = [];
|
|||||||
|
|
||||||
result = [ arrow = () => {} ] = vals;
|
result = [ arrow = () => {} ] = vals;
|
||||||
|
|
||||||
assert.sameValue(arrow.name, 'arrow');
|
verifyProperty(arrow, 'name', {
|
||||||
verifyNotEnumerable(arrow, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(arrow, 'name');
|
writable: false,
|
||||||
verifyConfigurable(arrow, 'name');
|
configurable: true,
|
||||||
|
value: 'arrow'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -37,9 +37,11 @@ result = [ xCls = class x {}, cls = class {}, xCls2 = class { static name() {} }
|
|||||||
assert(xCls.name !== 'xCls');
|
assert(xCls.name !== 'xCls');
|
||||||
assert(xCls2.name !== 'xCls2');
|
assert(xCls2.name !== 'xCls2');
|
||||||
|
|
||||||
assert.sameValue(cls.name, 'cls');
|
verifyProperty(cls, 'name', {
|
||||||
verifyNotEnumerable(cls, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(cls, 'name');
|
writable: false,
|
||||||
verifyConfigurable(cls, 'name');
|
configurable: true,
|
||||||
|
value: 'cls'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = [ xCover = (0, function() {}), cover = (function() {}) ] = vals;
|
|||||||
|
|
||||||
assert(xCover.name !== 'xCover');
|
assert(xCover.name !== 'xCover');
|
||||||
|
|
||||||
assert.sameValue(cover.name, 'cover');
|
verifyProperty(cover, 'name', {
|
||||||
verifyNotEnumerable(cover, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(cover, 'name');
|
writable: false,
|
||||||
verifyConfigurable(cover, 'name');
|
configurable: true,
|
||||||
|
value: 'cover'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = [ xFn = function x() {}, fn = function() {} ] = vals;
|
|||||||
|
|
||||||
assert(xFn.name !== 'xFn');
|
assert(xFn.name !== 'xFn');
|
||||||
|
|
||||||
assert.sameValue(fn.name, 'fn');
|
verifyProperty(fn, 'name', {
|
||||||
verifyNotEnumerable(fn, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(fn, 'name');
|
writable: false,
|
||||||
verifyConfigurable(fn, 'name');
|
configurable: true,
|
||||||
|
value: 'fn'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = [ xGen = function* x() {}, gen = function*() {} ] = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xGen.name, 'xGen');
|
assert.notSameValue(xGen.name, 'xGen');
|
||||||
|
|
||||||
assert.sameValue(gen.name, 'gen');
|
verifyProperty(gen, 'name', {
|
||||||
verifyNotEnumerable(gen, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(gen, 'name');
|
writable: false,
|
||||||
verifyConfigurable(gen, 'name');
|
configurable: true,
|
||||||
|
value: 'gen'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -33,9 +33,11 @@ var vals = {};
|
|||||||
|
|
||||||
result = { arrow = () => {} } = vals;
|
result = { arrow = () => {} } = vals;
|
||||||
|
|
||||||
assert.sameValue(arrow.name, 'arrow');
|
verifyProperty(arrow, 'name', {
|
||||||
verifyNotEnumerable(arrow, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(arrow, 'name');
|
writable: false,
|
||||||
verifyConfigurable(arrow, 'name');
|
configurable: true,
|
||||||
|
value: 'arrow'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = { xCls = class x {}, cls = class {}, xCls2 = class { static name() {} }
|
|||||||
assert.notSameValue(xCls.name, 'xCls');
|
assert.notSameValue(xCls.name, 'xCls');
|
||||||
assert.notSameValue(xCls2.name, 'xCls2');
|
assert.notSameValue(xCls2.name, 'xCls2');
|
||||||
|
|
||||||
assert.sameValue(cls.name, 'cls');
|
verifyProperty(cls, 'name', {
|
||||||
verifyNotEnumerable(cls, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(cls, 'name');
|
writable: false,
|
||||||
verifyConfigurable(cls, 'name');
|
configurable: true,
|
||||||
|
value: 'cls'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -35,9 +35,11 @@ result = { xCover = (0, function() {}), cover = (function() {}) } = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xCover.name, 'xCover');
|
assert.notSameValue(xCover.name, 'xCover');
|
||||||
|
|
||||||
assert.sameValue(cover.name, 'cover');
|
verifyProperty(cover, 'name', {
|
||||||
verifyNotEnumerable(cover, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(cover, 'name');
|
writable: false,
|
||||||
verifyConfigurable(cover, 'name');
|
configurable: true,
|
||||||
|
value: 'cover'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -35,9 +35,11 @@ result = { xFn = function x() {}, fn = function() {} } = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xFn.name, 'xFn');
|
assert.notSameValue(xFn.name, 'xFn');
|
||||||
|
|
||||||
assert.sameValue(fn.name, 'fn');
|
verifyProperty(fn, 'name', {
|
||||||
verifyNotEnumerable(fn, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(fn, 'name');
|
writable: false,
|
||||||
verifyConfigurable(fn, 'name');
|
configurable: true,
|
||||||
|
value: 'fn'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -35,9 +35,11 @@ result = { xGen = function* x() {}, gen = function*() {} } = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xGen.name, 'xGen');
|
assert.notSameValue(xGen.name, 'xGen');
|
||||||
|
|
||||||
assert.sameValue(gen.name, 'gen');
|
verifyProperty(gen, 'name', {
|
||||||
verifyNotEnumerable(gen, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(gen, 'name');
|
writable: false,
|
||||||
verifyConfigurable(gen, 'name');
|
configurable: true,
|
||||||
|
value: 'gen'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -34,9 +34,11 @@ var vals = {};
|
|||||||
|
|
||||||
result = { x: arrow = () => {} } = vals;
|
result = { x: arrow = () => {} } = vals;
|
||||||
|
|
||||||
assert.sameValue(arrow.name, 'arrow');
|
verifyProperty(arrow, 'name', {
|
||||||
verifyNotEnumerable(arrow, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(arrow, 'name');
|
writable: false,
|
||||||
verifyConfigurable(arrow, 'name');
|
configurable: true,
|
||||||
|
value: 'arrow'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -37,9 +37,11 @@ result = { x: xCls = class x {}, x: cls = class {}, x: xCls2 = class { static na
|
|||||||
assert.notSameValue(xCls.name, 'xCls');
|
assert.notSameValue(xCls.name, 'xCls');
|
||||||
assert.notSameValue(xCls2.name, 'xCls2');
|
assert.notSameValue(xCls2.name, 'xCls2');
|
||||||
|
|
||||||
assert.sameValue(cls.name, 'cls');
|
verifyProperty(cls, 'name', {
|
||||||
verifyNotEnumerable(cls, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(cls, 'name');
|
writable: false,
|
||||||
verifyConfigurable(cls, 'name');
|
configurable: true,
|
||||||
|
value: 'cls'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = { x: xCover = (0, function() {}), x: cover = (function() {}) } = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xCover.name, 'xCover');
|
assert.notSameValue(xCover.name, 'xCover');
|
||||||
|
|
||||||
assert.sameValue(cover.name, 'cover');
|
verifyProperty(cover, 'name', {
|
||||||
verifyNotEnumerable(cover, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(cover, 'name');
|
writable: false,
|
||||||
verifyConfigurable(cover, 'name');
|
configurable: true,
|
||||||
|
value: 'cover'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = { x: xFn = function x() {}, x: fn = function() {} } = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xFn.name, 'xFn');
|
assert.notSameValue(xFn.name, 'xFn');
|
||||||
|
|
||||||
assert.sameValue(fn.name, 'fn');
|
verifyProperty(fn, 'name', {
|
||||||
verifyNotEnumerable(fn, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(fn, 'name');
|
writable: false,
|
||||||
verifyConfigurable(fn, 'name');
|
configurable: true,
|
||||||
|
value: 'fn'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -36,9 +36,11 @@ result = { x: xGen = function* x() {}, x: gen = function*() {} } = vals;
|
|||||||
|
|
||||||
assert.notSameValue(xGen.name, 'xGen');
|
assert.notSameValue(xGen.name, 'xGen');
|
||||||
|
|
||||||
assert.sameValue(gen.name, 'gen');
|
verifyProperty(gen, 'name', {
|
||||||
verifyNotEnumerable(gen, 'name');
|
enumerable: false,
|
||||||
verifyNotWritable(gen, 'name');
|
writable: false,
|
||||||
verifyConfigurable(gen, 'name');
|
configurable: true,
|
||||||
|
value: 'gen'
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -27,16 +27,19 @@ var vals = obj;
|
|||||||
|
|
||||||
result = {...rest} = vals;
|
result = {...rest} = vals;
|
||||||
|
|
||||||
assert.sameValue(rest.a, 3);
|
verifyProperty(rest, "a", {
|
||||||
assert.sameValue(rest.b, 4);
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 3
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "b", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 4
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -25,12 +25,13 @@ var vals = { get v() { count++; return 2; } };
|
|||||||
|
|
||||||
result = {...x} = vals;
|
result = {...x} = vals;
|
||||||
|
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -26,17 +26,20 @@ var vals = obj;
|
|||||||
|
|
||||||
result = {...rest} = vals;
|
result = {...rest} = vals;
|
||||||
|
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(Object.getOwnPropertyDescriptor(rest, "x"), undefined);
|
assert.sameValue(Object.getOwnPropertyDescriptor(rest, "x"), undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -27,9 +27,10 @@ result = {...src.y} = vals;
|
|||||||
assert.sameValue(src.y.x, 1);
|
assert.sameValue(src.y.x, 1);
|
||||||
assert.sameValue(src.y.y, 2);
|
assert.sameValue(src.y.y, 2);
|
||||||
|
|
||||||
verifyEnumerable(src, "y");
|
verifyProperty(src, "y", {
|
||||||
verifyWritable(src, "y");
|
enumerable: true,
|
||||||
verifyConfigurable(src, "y");
|
writable: true,
|
||||||
|
configurable: true
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -25,18 +25,21 @@ var vals = {x: 1, y: 2, a: 5, b: 3};
|
|||||||
|
|
||||||
result = {a, b, ...rest} = vals;
|
result = {a, b, ...rest} = vals;
|
||||||
|
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
|
|
||||||
assert.sameValue(result, vals);
|
assert.sameValue(result, vals);
|
||||||
|
@ -23,13 +23,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function*({...x} = { get v() { count++; return 2; } }) {
|
f = async function*({...x} = { get v() { count++; return 2; } }) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -24,18 +24,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function*({...rest} = o) {
|
f = async function*({...rest} = o) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -22,19 +22,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function*({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
f = async function*({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -23,13 +23,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function* h({...x} = { get v() { count++; return 2; } }) {
|
f = async function* h({...x} = { get v() { count++; return 2; } }) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -24,18 +24,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function* h({...rest} = o) {
|
f = async function* h({...rest} = o) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -22,19 +22,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function* h({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
f = async function* h({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -23,13 +23,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function* h({...x}) {
|
f = async function* h({...x}) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -24,18 +24,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function* h({...rest}) {
|
f = async function* h({...rest}) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -22,19 +22,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function* h({a, b, ...rest}) {
|
f = async function* h({a, b, ...rest}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -23,13 +23,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function*({...x}) {
|
f = async function*({...x}) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -24,18 +24,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function*({...rest}) {
|
f = async function*({...rest}) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -22,19 +22,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var f;
|
var f;
|
||||||
f = async function*({a, b, ...rest}) {
|
f = async function*({a, b, ...rest}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -38,27 +38,35 @@ let o = {c: 3, d: 4};
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
|
|
||||||
(function(obj) {
|
(function(obj) {
|
||||||
assert.sameValue(obj.a, 1);
|
|
||||||
assert.sameValue(obj.b, 2);
|
|
||||||
assert.sameValue(obj.c, 3);
|
|
||||||
assert.sameValue(obj.d, 4);
|
|
||||||
assert.sameValue(Object.keys(obj).length, 4);
|
assert.sameValue(Object.keys(obj).length, 4);
|
||||||
|
|
||||||
verifyEnumerable(obj, "a");
|
verifyProperty(obj, "a", {
|
||||||
verifyWritable(obj, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 1
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "b");
|
verifyProperty(obj, "b", {
|
||||||
verifyWritable(obj, "b");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "b");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "c");
|
verifyProperty(obj, "c", {
|
||||||
verifyWritable(obj, "c");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "c");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 3
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "d");
|
verifyProperty(obj, "d", {
|
||||||
verifyWritable(obj, "d");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "d");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}({a: 1, b: 2, ...o}));
|
}({a: 1, b: 2, ...o}));
|
||||||
|
|
||||||
|
@ -42,14 +42,16 @@ let o = {
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
|
|
||||||
(function(obj) {
|
(function(obj) {
|
||||||
assert.sameValue(Object.getOwnPropertyDescriptor(obj, "a").value, 42);
|
|
||||||
assert.sameValue(obj.c, 4);
|
assert.sameValue(obj.c, 4);
|
||||||
assert.sameValue(obj.d, 5);
|
assert.sameValue(obj.d, 5);
|
||||||
assert.sameValue(Object.keys(obj).length, 3);
|
assert.sameValue(Object.keys(obj).length, 3);
|
||||||
|
|
||||||
verifyEnumerable(obj, "a");
|
verifyProperty(obj, "a", {
|
||||||
verifyWritable(obj, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 42
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}({...o, c: 4, d: 5}));
|
}({...o, c: 4, d: 5}));
|
||||||
|
|
||||||
|
@ -32,14 +32,19 @@ var callCount = 0;
|
|||||||
assert.sameValue(obj.a, 3)
|
assert.sameValue(obj.a, 3)
|
||||||
assert.sameValue(obj.b, 2);
|
assert.sameValue(obj.b, 2);
|
||||||
|
|
||||||
verifyEnumerable(obj, "a");
|
verifyProperty(obj, "a", {
|
||||||
verifyWritable(obj, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(obj, "b");
|
value: 3
|
||||||
verifyWritable(obj, "b");
|
});
|
||||||
verifyConfigurable(obj, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(obj, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}({...o, a: 3}));
|
}({...o, a: 3}));
|
||||||
|
|
||||||
|
@ -38,17 +38,21 @@ let o = {c: 3, d: 4};
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
|
|
||||||
(function(obj) {
|
(function(obj) {
|
||||||
assert.sameValue(obj.c, 3);
|
|
||||||
assert.sameValue(obj.d, 4);
|
|
||||||
assert.sameValue(Object.keys(obj).length, 2);
|
assert.sameValue(Object.keys(obj).length, 2);
|
||||||
|
|
||||||
verifyEnumerable(obj, "c");
|
verifyProperty(obj, "c", {
|
||||||
verifyWritable(obj, "c");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "c");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 3
|
||||||
|
});
|
||||||
|
|
||||||
verifyEnumerable(obj, "d");
|
verifyProperty(obj, "d", {
|
||||||
verifyWritable(obj, "d");
|
enumerable: true,
|
||||||
verifyConfigurable(obj, "d");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount += 1;
|
callCount += 1;
|
||||||
}({...o}));
|
}({...o}));
|
||||||
|
|
||||||
|
@ -47,13 +47,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
async *method({...x} = { get v() { count++; return 2; } }) {
|
async *method({...x} = { get v() { count++; return 2; } }) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -48,18 +48,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
async *method({...rest} = o) {
|
async *method({...rest} = o) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -46,19 +46,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
async *method({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
async *method({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -47,13 +47,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
async *method({...x}) {
|
async *method({...x}) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -48,18 +48,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
async *method({...rest}) {
|
async *method({...rest}) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -46,19 +46,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
async *method({a, b, ...rest}) {
|
async *method({a, b, ...rest}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -47,13 +47,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
static async *method({...x} = { get v() { count++; return 2; } }) {
|
static async *method({...x} = { get v() { count++; return 2; } }) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -48,18 +48,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
static async *method({...rest} = o) {
|
static async *method({...rest} = o) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -46,19 +46,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
static async *method({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
static async *method({a, b, ...rest} = {x: 1, y: 2, a: 5, b: 3}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -47,13 +47,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
static async *method({...x}) {
|
static async *method({...x}) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -48,18 +48,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
static async *method({...rest}) {
|
static async *method({...rest}) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -46,19 +46,22 @@ info: |
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
static async *method({a, b, ...rest}) {
|
static async *method({a, b, ...rest}) {
|
||||||
assert.sameValue(rest.x, 1);
|
|
||||||
assert.sameValue(rest.y, 2);
|
|
||||||
assert.sameValue(rest.a, undefined);
|
assert.sameValue(rest.a, undefined);
|
||||||
assert.sameValue(rest.b, undefined);
|
assert.sameValue(rest.b, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "x");
|
verifyProperty(rest, "x", {
|
||||||
verifyWritable(rest, "x");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "x");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "y");
|
value: 1
|
||||||
verifyWritable(rest, "y");
|
});
|
||||||
verifyConfigurable(rest, "y");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "y", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -67,13 +67,14 @@ var count = 0;
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
*method({...x} = { get v() { count++; return 2; } }) {
|
*method({...x} = { get v() { count++; return 2; } }) {
|
||||||
assert.sameValue(x.v, 2);
|
|
||||||
assert.sameValue(count, 1);
|
assert.sameValue(count, 1);
|
||||||
|
|
||||||
verifyEnumerable(x, "v");
|
verifyProperty(x, "v", {
|
||||||
verifyWritable(x, "v");
|
enumerable: true,
|
||||||
verifyConfigurable(x, "v");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 2
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -68,18 +68,21 @@ Object.defineProperty(o, "x", { value: 4, enumerable: false });
|
|||||||
var callCount = 0;
|
var callCount = 0;
|
||||||
var C = class {
|
var C = class {
|
||||||
*method({...rest} = o) {
|
*method({...rest} = o) {
|
||||||
assert.sameValue(rest.a, 3);
|
|
||||||
assert.sameValue(rest.b, 4);
|
|
||||||
assert.sameValue(rest.x, undefined);
|
assert.sameValue(rest.x, undefined);
|
||||||
|
|
||||||
verifyEnumerable(rest, "a");
|
verifyProperty(rest, "a", {
|
||||||
verifyWritable(rest, "a");
|
enumerable: true,
|
||||||
verifyConfigurable(rest, "a");
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
verifyEnumerable(rest, "b");
|
value: 3
|
||||||
verifyWritable(rest, "b");
|
});
|
||||||
verifyConfigurable(rest, "b");
|
|
||||||
|
|
||||||
|
verifyProperty(rest, "b", {
|
||||||
|
enumerable: true,
|
||||||
|
writable: true,
|
||||||
|
configurable: true,
|
||||||
|
value: 4
|
||||||
|
});
|
||||||
callCount = callCount + 1;
|
callCount = callCount + 1;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user