mirror of https://github.com/tc39/test262.git
built-ins/ThrowTypeError/*: make all indentation consistent (depth & character) (#1427)
This commit is contained in:
parent
621d34d5ea
commit
bc70e0339f
|
@ -13,7 +13,10 @@ features: [cross-realm]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var other = $262.createRealm().global;
|
var other = $262.createRealm().global;
|
||||||
var localArgs = function(){ "use strict"; return arguments; }();
|
var localArgs = function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}();
|
||||||
var otherArgs = (new other.Function('return arguments;'))();
|
var otherArgs = (new other.Function('return arguments;'))();
|
||||||
var localThrowTypeError = Object.getOwnPropertyDescriptor(localArgs, "callee").get;
|
var localThrowTypeError = Object.getOwnPropertyDescriptor(localArgs, "callee").get;
|
||||||
var otherThrowTypeError = Object.getOwnPropertyDescriptor(otherArgs, "callee").get;
|
var otherThrowTypeError = Object.getOwnPropertyDescriptor(otherArgs, "callee").get;
|
||||||
|
|
|
@ -12,6 +12,9 @@ info: |
|
||||||
function is false.
|
function is false.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(Object.isExtensible(ThrowTypeError), false);
|
assert.sameValue(Object.isExtensible(ThrowTypeError), false);
|
||||||
|
|
|
@ -25,6 +25,9 @@ info: |
|
||||||
properties.
|
properties.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(Object.prototype.hasOwnProperty.call(ThrowTypeError, "arguments"), false);
|
assert.sameValue(Object.prototype.hasOwnProperty.call(ThrowTypeError, "arguments"), false);
|
||||||
|
|
|
@ -25,6 +25,9 @@ info: |
|
||||||
properties.
|
properties.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(Object.prototype.hasOwnProperty.call(ThrowTypeError, "caller"), false);
|
assert.sameValue(Object.prototype.hasOwnProperty.call(ThrowTypeError, "caller"), false);
|
||||||
|
|
|
@ -14,6 +14,9 @@ info: |
|
||||||
{ [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }.
|
{ [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: false }.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(Object.isFrozen(ThrowTypeError), true);
|
assert.sameValue(Object.isFrozen(ThrowTypeError), true);
|
||||||
|
|
|
@ -12,6 +12,9 @@ info: |
|
||||||
object that is defined once for each realm.
|
object that is defined once for each realm.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(typeof ThrowTypeError, "function");
|
assert.sameValue(typeof ThrowTypeError, "function");
|
||||||
|
|
|
@ -13,7 +13,10 @@ info: |
|
||||||
includes: [propertyHelper.js]
|
includes: [propertyHelper.js]
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(ThrowTypeError.length, 0);
|
assert.sameValue(ThrowTypeError.length, 0);
|
||||||
|
|
||||||
|
|
|
@ -12,6 +12,9 @@ info: |
|
||||||
object that is defined once for each Realm.
|
object that is defined once for each Realm.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(Object.prototype.hasOwnProperty.call(ThrowTypeError, "name"), false);
|
assert.sameValue(Object.prototype.hasOwnProperty.call(ThrowTypeError, "name"), false);
|
||||||
|
|
|
@ -19,6 +19,9 @@ info: |
|
||||||
...
|
...
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.sameValue(Object.getPrototypeOf(ThrowTypeError), Function.prototype);
|
assert.sameValue(Object.getPrototypeOf(ThrowTypeError), Function.prototype);
|
||||||
|
|
|
@ -13,7 +13,10 @@ info: |
|
||||||
1. Throw a TypeError exception.
|
1. Throw a TypeError exception.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
assert.throws(TypeError, function() {
|
assert.throws(TypeError, function() {
|
||||||
ThrowTypeError();
|
ThrowTypeError();
|
||||||
|
|
|
@ -12,7 +12,10 @@ info: |
|
||||||
object that is defined once for each realm.
|
object that is defined once for each realm.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
// Test with Function.prototype.arguments and Function.prototype.caller properties.
|
// Test with Function.prototype.arguments and Function.prototype.caller properties.
|
||||||
var argumentsDesc = Object.getOwnPropertyDescriptor(Function.prototype, "arguments");
|
var argumentsDesc = Object.getOwnPropertyDescriptor(Function.prototype, "arguments");
|
||||||
|
|
|
@ -12,7 +12,10 @@ info: |
|
||||||
object that is defined once for each realm.
|
object that is defined once for each realm.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
// Test with unmapped arguments object from function with non-simple parameters list.
|
// Test with unmapped arguments object from function with non-simple parameters list.
|
||||||
function nonSimple(a = 0) {
|
function nonSimple(a = 0) {
|
||||||
|
|
|
@ -12,7 +12,10 @@ info: |
|
||||||
object that is defined once for each realm.
|
object that is defined once for each realm.
|
||||||
---*/
|
---*/
|
||||||
|
|
||||||
var ThrowTypeError = Object.getOwnPropertyDescriptor(function(){ "use strict"; return arguments; }(), "callee").get;
|
var ThrowTypeError = Object.getOwnPropertyDescriptor(function() {
|
||||||
|
"use strict";
|
||||||
|
return arguments;
|
||||||
|
}(), "callee").get;
|
||||||
|
|
||||||
// Test with unmapped arguments object from strict-mode function.
|
// Test with unmapped arguments object from strict-mode function.
|
||||||
function strictFn() {
|
function strictFn() {
|
||||||
|
|
Loading…
Reference in New Issue