chore: migrate $ERROR -> throw new Test262Error in test/built-ins/global (#3084)

This commit is contained in:
Rick Waldron 2021-07-21 15:09:22 -04:00 committed by GitHub
parent 02733c5af4
commit a101757ca1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
20 changed files with 148 additions and 148 deletions

View File

@ -11,15 +11,15 @@ description: Global execution context - Value Properties
//CHECK#1
if (NaN === null) {
$ERROR("#1: NaN === null");
throw new Test262Error("#1: NaN === null");
}
//CHECK#2
if (Infinity === null) {
$ERROR("#2: Infinity === null");
throw new Test262Error("#2: Infinity === null");
}
//CHECK#3
if (undefined === null) {
$ERROR("#3: undefined === null");
throw new Test262Error("#3: undefined === null");
}

View File

@ -11,45 +11,45 @@ description: Global execution context - Function Properties
//CHECK#4
if (eval === null) {
$ERROR("#4: eval === null");
throw new Test262Error("#4: eval === null");
}
//CHECK#5
if (parseInt === null) {
$ERROR("#5: parseInt === null");
throw new Test262Error("#5: parseInt === null");
}
//CHECK#6
if (parseFloat === null) {
$ERROR("#6: parseFloat === null");
throw new Test262Error("#6: parseFloat === null");
}
//CHECK#7
if (isNaN === null) {
$ERROR("#7: isNaN === null");
throw new Test262Error("#7: isNaN === null");
}
//CHECK#8
if (isFinite === null) {
$ERROR("#8: isFinite === null");
throw new Test262Error("#8: isFinite === null");
}
//CHECK#9
if (decodeURI === null) {
$ERROR("#9: decodeURI === null");
throw new Test262Error("#9: decodeURI === null");
}
//CHECK#10
if (decodeURIComponent === null) {
$ERROR("#10: decodeURIComponent === null");
throw new Test262Error("#10: decodeURIComponent === null");
}
//CHECK#11
if (encodeURI === null) {
$ERROR("#11: encodeURI === null");
throw new Test262Error("#11: encodeURI === null");
}
//CHECK#12
if (encodeURIComponent === null) {
$ERROR("#12: encodeURIComponent === null");
throw new Test262Error("#12: encodeURIComponent === null");
}

View File

@ -11,75 +11,75 @@ description: Global execution context - Constructor Properties
//CHECK#13
if (Object === null) {
$ERROR("#13: Object === null");
throw new Test262Error("#13: Object === null");
}
//CHECK#14
if (Function === null) {
$ERROR("#14: Function === null");
throw new Test262Error("#14: Function === null");
}
//CHECK#15
if (String === null) {
$ERROR("#15: String === null");
throw new Test262Error("#15: String === null");
}
//CHECK#16
if (Number === null) {
$ERROR("#16: Number === null");
throw new Test262Error("#16: Number === null");
}
//CHECK#17
if (Array === null) {
$ERROR("#17: Array === null");
throw new Test262Error("#17: Array === null");
}
//CHECK#18
if (Boolean === null) {
$ERROR("#20: Boolean === null");
throw new Test262Error("#20: Boolean === null");
}
//CHECK#18
if (Date === null) {
$ERROR("#18: Date === null");
throw new Test262Error("#18: Date === null");
}
//CHECK#19
if (RegExp === null) {
$ERROR("#19: RegExp === null");
throw new Test262Error("#19: RegExp === null");
}
//CHECK#20
if (Error === null) {
$ERROR("#20: Error === null");
throw new Test262Error("#20: Error === null");
}
//CHECK#21
if (EvalError === null) {
$ERROR("#21: EvalError === null");
throw new Test262Error("#21: EvalError === null");
}
//CHECK#22
if (RangeError === null) {
$ERROR("#22: RangeError === null");
throw new Test262Error("#22: RangeError === null");
}
//CHECK#23
if (ReferenceError === null) {
$ERROR("#23: ReferenceError === null");
throw new Test262Error("#23: ReferenceError === null");
}
//CHECK#24
if (SyntaxError === null) {
$ERROR("#24: SyntaxError === null");
throw new Test262Error("#24: SyntaxError === null");
}
//CHECK#25
if (TypeError === null) {
$ERROR("#25: TypeError === null");
throw new Test262Error("#25: TypeError === null");
}
//CHECK#26
if (URIError === null) {
$ERROR("#26: URIError === null");
throw new Test262Error("#26: URIError === null");
}

View File

@ -11,5 +11,5 @@ description: Global execution context - Other Properties
//CHECK#27
if (Math === null) {
$ERROR("#27: Math === null");
throw new Test262Error("#27: Math === null");
}

View File

@ -12,17 +12,17 @@ description: Function execution context - Value Properties
function test() {
//CHECK#1
if (NaN === null) {
$ERROR("#1: NaN === null");
throw new Test262Error("#1: NaN === null");
}
//CHECK#2
if (Infinity === null) {
$ERROR("#2: Infinity === null");
throw new Test262Error("#2: Infinity === null");
}
//CHECK#3
if (undefined === null) {
$ERROR("#3: undefined === null");
throw new Test262Error("#3: undefined === null");
}
}

View File

@ -12,47 +12,47 @@ description: Function execution context - Function Properties
function test() {
//CHECK#4
if (eval === null) {
$ERROR("#4: eval === null");
throw new Test262Error("#4: eval === null");
}
//CHECK#5
if (parseInt === null) {
$ERROR("#5: parseInt === null");
throw new Test262Error("#5: parseInt === null");
}
//CHECK#6
if (parseFloat === null) {
$ERROR("#6: parseFloat === null");
throw new Test262Error("#6: parseFloat === null");
}
//CHECK#7
if (isNaN === null) {
$ERROR("#7: isNaN === null");
throw new Test262Error("#7: isNaN === null");
}
//CHECK#8
if (isFinite === null) {
$ERROR("#8: isFinite === null");
throw new Test262Error("#8: isFinite === null");
}
//CHECK#9
if (decodeURI === null) {
$ERROR("#9: decodeURI === null");
throw new Test262Error("#9: decodeURI === null");
}
//CHECK#10
if (decodeURIComponent === null) {
$ERROR("#10: decodeURIComponent === null");
throw new Test262Error("#10: decodeURIComponent === null");
}
//CHECK#11
if (encodeURI === null) {
$ERROR("#11: encodeURI === null");
throw new Test262Error("#11: encodeURI === null");
}
//CHECK#12
if (encodeURIComponent === null) {
$ERROR("#12: encodeURIComponent === null");
throw new Test262Error("#12: encodeURIComponent === null");
}
}

View File

@ -12,77 +12,77 @@ description: Function execution context - Constructor Properties
function test() {
//CHECK#13
if (Object === null) {
$ERROR("#13: Object === null");
throw new Test262Error("#13: Object === null");
}
//CHECK#14
if (Function === null) {
$ERROR("#14: Function === null");
throw new Test262Error("#14: Function === null");
}
//CHECK#15
if (String === null) {
$ERROR("#15: String === null");
throw new Test262Error("#15: String === null");
}
//CHECK#16
if (Number === null) {
$ERROR("#16: Function === null");
throw new Test262Error("#16: Function === null");
}
//CHECK#17
if (Array === null) {
$ERROR("#17: Array === null");
throw new Test262Error("#17: Array === null");
}
//CHECK#18
if (Boolean === null) {
$ERROR("#20: Boolean === null");
throw new Test262Error("#20: Boolean === null");
}
//CHECK#18
if (Date === null) {
$ERROR("#18: Date === null");
throw new Test262Error("#18: Date === null");
}
//CHECK#19
if (RegExp === null) {
$ERROR("#19: RegExp === null");
throw new Test262Error("#19: RegExp === null");
}
//CHECK#20
if (Error === null) {
$ERROR("#20: Error === null");
throw new Test262Error("#20: Error === null");
}
//CHECK#21
if (EvalError === null) {
$ERROR("#21: EvalError === null");
throw new Test262Error("#21: EvalError === null");
}
//CHECK#22
if (RangeError === null) {
$ERROR("#22: RangeError === null");
throw new Test262Error("#22: RangeError === null");
}
//CHECK#23
if (ReferenceError === null) {
$ERROR("#23: ReferenceError === null");
throw new Test262Error("#23: ReferenceError === null");
}
//CHECK#24
if (SyntaxError === null) {
$ERROR("#24: SyntaxError === null");
throw new Test262Error("#24: SyntaxError === null");
}
//CHECK#25
if (TypeError === null) {
$ERROR("#25: TypeError === null");
throw new Test262Error("#25: TypeError === null");
}
//CHECK#26
if (URIError === null) {
$ERROR("#26: URIError === null");
throw new Test262Error("#26: URIError === null");
}
}

View File

@ -12,7 +12,7 @@ description: Function execution context - Other Properties
function test() {
//CHECK#27
if (Math === null) {
$ERROR("#27: Math === null");
throw new Test262Error("#27: Math === null");
}
}

View File

@ -9,20 +9,20 @@ es5id: 10.2.3_A1.3_T1
description: Eval execution context - Value Properties
---*/
var evalStr =
var evalStr =
'//CHECK#1\n'+
'if ( NaN === null ) {\n'+
' $ERROR("#1: NaN === null");\n'+
' throw new Test262Error("#1: NaN === null");\n'+
'}\n'+
'//CHECK#2\n'+
'if ( Infinity === null ) {\n'+
' $ERROR("#2: Infinity === null");\n'+
' throw new Test262Error("#2: Infinity === null");\n'+
'}\n'+
'//CHECK#3\n'+
'if ( undefined === null ) {\n'+
' $ERROR("#3: undefined === null");\n'+
' throw new Test262Error("#3: undefined === null");\n'+
'}\n'+
';\n';

View File

@ -9,50 +9,50 @@ es5id: 10.2.3_A1.3_T2
description: Eval execution context - Function Properties
---*/
var evalStr =
var evalStr =
'//CHECK#4\n'+
'if ( eval === null ) {\n'+
' $ERROR("#4: eval === null");\n'+
' throw new Test262Error("#4: eval === null");\n'+
'}\n'+
'//CHECK#5\n'+
'if ( parseInt === null ) {\n'+
' $ERROR("#5: parseInt === null");\n'+
' throw new Test262Error("#5: parseInt === null");\n'+
'}\n'+
'//CHECK#6\n'+
'if ( parseFloat === null ) {\n'+
' $ERROR("#6: parseFloat === null");\n'+
' throw new Test262Error("#6: parseFloat === null");\n'+
'}\n'+
'//CHECK#7\n'+
'if ( isNaN === null ) {\n'+
' $ERROR("#7: isNaN === null");\n'+
' throw new Test262Error("#7: isNaN === null");\n'+
'}\n'+
'//CHECK#8\n'+
'if ( isFinite === null ) {\n'+
' $ERROR("#8: isFinite === null");\n'+
' throw new Test262Error("#8: isFinite === null");\n'+
'}\n'+
'//CHECK#9\n'+
'if ( decodeURI === null ) {\n'+
' $ERROR("#9: decodeURI === null");\n'+
' throw new Test262Error("#9: decodeURI === null");\n'+
'}\n'+
'//CHECK#10\n'+
'if ( decodeURIComponent === null ) {\n'+
' $ERROR("#10: decodeURIComponent === null");\n'+
' throw new Test262Error("#10: decodeURIComponent === null");\n'+
'}\n'+
'//CHECK#11\n'+
'if ( encodeURI === null ) {\n'+
' $ERROR("#11: encodeURI === null");\n'+
' throw new Test262Error("#11: encodeURI === null");\n'+
'}\n'+
'//CHECK#12\n'+
'if ( encodeURIComponent === null ) {\n'+
' $ERROR("#12: encodeURIComponent === null");\n'+
' throw new Test262Error("#12: encodeURIComponent === null");\n'+
'}\n'+
';\n';

View File

@ -9,80 +9,80 @@ es5id: 10.2.3_A1.3_T3
description: Eval execution context - Constructor Properties
---*/
var evalStr =
var evalStr =
'//CHECK#13\n'+
'if ( Object === null ) {\n'+
' $ERROR("#13: Object === null");\n'+
' throw new Test262Error("#13: Object === null");\n'+
'}\n'+
'//CHECK#14\n'+
'if ( Function === null ) {\n'+
' $ERROR("#14: Function === null");\n'+
' throw new Test262Error("#14: Function === null");\n'+
'}\n'+
'//CHECK#15\n'+
'if ( String === null ) {\n'+
' $ERROR("#15: String === null");\n'+
' throw new Test262Error("#15: String === null");\n'+
'}\n'+
'//CHECK#16\n'+
'if ( Number === null ) {\n'+
' $ERROR("#16: Function === null");\n'+
' throw new Test262Error("#16: Function === null");\n'+
'}\n'+
'//CHECK#17\n'+
'if ( Array === null ) {\n'+
' $ERROR("#17: Array === null");\n'+
' throw new Test262Error("#17: Array === null");\n'+
'}\n'+
'//CHECK#18\n'+
'if ( Boolean === null ) {\n'+
' $ERROR("#20: Boolean === null");\n'+
' throw new Test262Error("#20: Boolean === null");\n'+
'}\n'+
'//CHECK#18\n'+
'if ( Date === null ) {\n'+
' $ERROR("#18: Date === null");\n'+
' throw new Test262Error("#18: Date === null");\n'+
'}\n'+
'//CHECK#19\n'+
'if ( RegExp === null ) {\n'+
' $ERROR("#19: RegExp === null");\n'+
' throw new Test262Error("#19: RegExp === null");\n'+
'}\n'+
'//CHECK#20\n'+
'if ( Error === null ) {\n'+
' $ERROR("#20: Error === null");\n'+
' throw new Test262Error("#20: Error === null");\n'+
'}\n'+
'//CHECK#21\n'+
'if ( EvalError === null ) {\n'+
' $ERROR("#21: EvalError === null");\n'+
' throw new Test262Error("#21: EvalError === null");\n'+
'}\n'+
'//CHECK#22\n'+
'if ( RangeError === null ) {\n'+
' $ERROR("#22: RangeError === null");\n'+
' throw new Test262Error("#22: RangeError === null");\n'+
'}\n'+
'//CHECK#23\n'+
'if ( ReferenceError === null ) {\n'+
' $ERROR("#23: ReferenceError === null");\n'+
' throw new Test262Error("#23: ReferenceError === null");\n'+
'}\n'+
'//CHECK#24\n'+
'if ( SyntaxError === null ) {\n'+
' $ERROR("#24: SyntaxError === null");\n'+
' throw new Test262Error("#24: SyntaxError === null");\n'+
'}\n'+
'//CHECK#25\n'+
'if ( TypeError === null ) {\n'+
' $ERROR("#25: TypeError === null");\n'+
' throw new Test262Error("#25: TypeError === null");\n'+
'}\n'+
'//CHECK#26\n'+
'if ( URIError === null ) {\n'+
' $ERROR("#26: URIError === null");\n'+
' throw new Test262Error("#26: URIError === null");\n'+
'}\n'+
';\n';

View File

@ -9,10 +9,10 @@ es5id: 10.2.3_A1.3_T4
description: Eval execution context - Other Properties
---*/
var evalStr =
var evalStr =
'//CHECK#27\n'+
'if ( Math === null ) {\n'+
' $ERROR("#27: Math === null");\n'+
' throw new Test262Error("#27: Math === null");\n'+
'}\n'+
';\n';

View File

@ -10,10 +10,10 @@ description: Global execution context - Value Properties
//CHECK#1
for (var x in this) {
if (x === 'NaN') {
$ERROR("#1: 'NaN' have attribute DontEnum");
throw new Test262Error("#1: 'NaN' have attribute DontEnum");
} else if (x === 'Infinity') {
$ERROR("#1: 'Infinity' have attribute DontEnum");
throw new Test262Error("#1: 'Infinity' have attribute DontEnum");
} else if (x === 'undefined') {
$ERROR("#1: 'undefined' have attribute DontEnum");
throw new Test262Error("#1: 'undefined' have attribute DontEnum");
}
}

View File

@ -10,22 +10,22 @@ description: Global execution context - Function Properties
//CHECK#1
for (var x in this) {
if (x === 'eval') {
$ERROR("#1: 'eval' have attribute DontEnum");
throw new Test262Error("#1: 'eval' have attribute DontEnum");
} else if (x === 'parseInt') {
$ERROR("#1: 'parseInt' have attribute DontEnum");
throw new Test262Error("#1: 'parseInt' have attribute DontEnum");
} else if (x === 'parseFloat') {
$ERROR("#1: 'parseFloat' have attribute DontEnum");
throw new Test262Error("#1: 'parseFloat' have attribute DontEnum");
} else if (x === 'isNaN') {
$ERROR("#1: 'isNaN' have attribute DontEnum");
throw new Test262Error("#1: 'isNaN' have attribute DontEnum");
} else if (x === 'isFinite') {
$ERROR("#1: 'isFinite' have attribute DontEnum");
throw new Test262Error("#1: 'isFinite' have attribute DontEnum");
} else if (x === 'decodeURI') {
$ERROR("#1: 'decodeURI' have attribute DontEnum");
throw new Test262Error("#1: 'decodeURI' have attribute DontEnum");
} else if (x === 'decodeURIComponent') {
$ERROR("#1: 'decodeURIComponent' have attribute DontEnum");
throw new Test262Error("#1: 'decodeURIComponent' have attribute DontEnum");
} else if (x === 'encodeURI') {
$ERROR("#1: 'encodeURI' have attribute DontEnum");
throw new Test262Error("#1: 'encodeURI' have attribute DontEnum");
} else if (x === 'encodeURIComponent') {
$ERROR("#1: 'encodeURIComponent' have attribute DontEnum");
throw new Test262Error("#1: 'encodeURIComponent' have attribute DontEnum");
}
}

View File

@ -10,34 +10,34 @@ description: Global execution context - Constructor Properties
//CHECK#1
for (var x in this) {
if (x === 'Object') {
$ERROR("#1: 'property 'Object' have attribute DontEnum");
throw new Test262Error("#1: 'property 'Object' have attribute DontEnum");
} else if (x === 'Function') {
$ERROR("#1: 'Function' have attribute DontEnum");
throw new Test262Error("#1: 'Function' have attribute DontEnum");
} else if (x === 'String') {
$ERROR("#1: 'String' have attribute DontEnum");
throw new Test262Error("#1: 'String' have attribute DontEnum");
} else if (x === 'Number') {
$ERROR("#1: 'Number' have attribute DontEnum");
throw new Test262Error("#1: 'Number' have attribute DontEnum");
} else if (x === 'Array') {
$ERROR("#1: 'Array' have attribute DontEnum");
throw new Test262Error("#1: 'Array' have attribute DontEnum");
} else if (x === 'Boolean') {
$ERROR("#1: 'Boolean' have attribute DontEnum");
throw new Test262Error("#1: 'Boolean' have attribute DontEnum");
} else if (x === 'Date') {
$ERROR("#1: 'Date' have attribute DontEnum");
throw new Test262Error("#1: 'Date' have attribute DontEnum");
} else if (x === 'RegExp') {
$ERROR("#1: 'RegExp' have attribute DontEnum");
throw new Test262Error("#1: 'RegExp' have attribute DontEnum");
} else if (x === 'Error') {
$ERROR("#1: 'Error' have attribute DontEnum");
throw new Test262Error("#1: 'Error' have attribute DontEnum");
} else if (x === 'EvalError') {
$ERROR("#1: 'EvalError' have attribute DontEnum");
throw new Test262Error("#1: 'EvalError' have attribute DontEnum");
} else if (x === 'RangeError') {
$ERROR("#1: 'RangeError' have attribute DontEnum");
throw new Test262Error("#1: 'RangeError' have attribute DontEnum");
} else if (x === 'ReferenceError') {
$ERROR("#1: 'ReferenceError' have attribute DontEnum");
throw new Test262Error("#1: 'ReferenceError' have attribute DontEnum");
} else if (x === 'SyntaxError') {
$ERROR("#1: 'SyntaxError' have attribute DontEnum");
throw new Test262Error("#1: 'SyntaxError' have attribute DontEnum");
} else if (x === 'TypeError') {
$ERROR("#1: 'TypeError' have attribute DontEnum");
throw new Test262Error("#1: 'TypeError' have attribute DontEnum");
} else if (x === 'URIError') {
$ERROR("#1: 'URIError' have attribute DontEnum");
throw new Test262Error("#1: 'URIError' have attribute DontEnum");
}
}

View File

@ -10,6 +10,6 @@ description: Global execution context - Other Properties
//CHECK#1
for (var x in this) {
if (x === 'Math') {
$ERROR("#1: 'Math' have attribute DontEnum");
throw new Test262Error("#1: 'Math' have attribute DontEnum");
}
}

View File

@ -7,15 +7,15 @@ es5id: 10.2.3_A2.3_T1
description: Global execution context - Value Properties
---*/
var evalStr =
var evalStr =
'//CHECK#1\n'+
'for (var x in this) {\n'+
' if ( x === \'NaN\' ) {\n'+
' $ERROR("#1: \'NaN\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'NaN\' have attribute DontEnum");\n'+
' } else if ( x === \'Infinity\' ) {\n'+
' $ERROR("#1: \'Infinity\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Infinity\' have attribute DontEnum");\n'+
' } else if ( x === \'undefined\' ) {\n'+
' $ERROR("#1: \'undefined\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'undefined\' have attribute DontEnum");\n'+
' }\n'+
'}\n';

View File

@ -7,27 +7,27 @@ es5id: 10.2.3_A2.3_T2
description: Global execution context - Function Properties
---*/
var evalStr =
var evalStr =
'//CHECK#1\n'+
'for (var x in this) {\n'+
' if ( x === \'eval\' ) {\n'+
' $ERROR("#1: \'eval\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'eval\' have attribute DontEnum");\n'+
' } else if ( x === \'parseInt\' ) {\n'+
' $ERROR("#1: \'parseInt\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'parseInt\' have attribute DontEnum");\n'+
' } else if ( x === \'parseFloat\' ) {\n'+
' $ERROR("#1: \'parseFloat\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'parseFloat\' have attribute DontEnum");\n'+
' } else if ( x === \'isNaN\' ) {\n'+
' $ERROR("#1: \'isNaN\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'isNaN\' have attribute DontEnum");\n'+
' } else if ( x === \'isFinite\' ) {\n'+
' $ERROR("#1: \'isFinite\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'isFinite\' have attribute DontEnum");\n'+
' } else if ( x === \'decodeURI\' ) {\n'+
' $ERROR("#1: \'decodeURI\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'decodeURI\' have attribute DontEnum");\n'+
' } else if ( x === \'decodeURIComponent\' ) {\n'+
' $ERROR("#1: \'decodeURIComponent\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'decodeURIComponent\' have attribute DontEnum");\n'+
' } else if ( x === \'encodeURI\' ) {\n'+
' $ERROR("#1: \'encodeURI\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'encodeURI\' have attribute DontEnum");\n'+
' } else if ( x === \'encodeURIComponent\' ) {\n'+
' $ERROR("#1: \'encodeURIComponent\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'encodeURIComponent\' have attribute DontEnum");\n'+
' }\n'+
'}\n';

View File

@ -7,39 +7,39 @@ es5id: 10.2.3_A2.3_T3
description: Global execution context - Constructor Properties
---*/
var evalStr =
var evalStr =
'//CHECK#1\n'+
'for (var x in this) {\n'+
' if ( x === \'Object\' ) {\n'+
' $ERROR("#1: \'Object\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Object\' have attribute DontEnum");\n'+
' } else if ( x === \'Function\') {\n'+
' $ERROR("#1: \'Function\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Function\' have attribute DontEnum");\n'+
' } else if ( x === \'String\' ) {\n'+
' $ERROR("#1: \'String\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'String\' have attribute DontEnum");\n'+
' } else if ( x === \'Number\' ) {\n'+
' $ERROR("#1: \'Number\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Number\' have attribute DontEnum");\n'+
' } else if ( x === \'Array\' ) {\n'+
' $ERROR("#1: \'Array\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Array\' have attribute DontEnum");\n'+
' } else if ( x === \'Boolean\' ) {\n'+
' $ERROR("#1: \'Boolean\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Boolean\' have attribute DontEnum");\n'+
' } else if ( x === \'Date\' ) {\n'+
' $ERROR("#1: \'Date\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Date\' have attribute DontEnum");\n'+
' } else if ( x === \'RegExp\' ) {\n'+
' $ERROR("#1: \'RegExp\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'RegExp\' have attribute DontEnum");\n'+
' } else if ( x === \'Error\' ) {\n'+
' $ERROR("#1: \'Error\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Error\' have attribute DontEnum");\n'+
' } else if ( x === \'EvalError\' ) {\n'+
' $ERROR("#1: \'EvalError\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'EvalError\' have attribute DontEnum");\n'+
' } else if ( x === \'RangeError\' ) {\n'+
' $ERROR("#1: \'RangeError\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'RangeError\' have attribute DontEnum");\n'+
' } else if ( x === \'ReferenceError\' ) {\n'+
' $ERROR("#1: \'ReferenceError\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'ReferenceError\' have attribute DontEnum");\n'+
' } else if ( x === \'SyntaxError\' ) {\n'+
' $ERROR("#1: \'SyntaxError\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'SyntaxError\' have attribute DontEnum");\n'+
' } else if ( x === \'TypeError\' ) {\n'+
' $ERROR("#1: \'TypeError\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'TypeError\' have attribute DontEnum");\n'+
' } else if ( x === \'URIError\' ) {\n'+
' $ERROR("#1: \'URIError\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'URIError\' have attribute DontEnum");\n'+
' }\n'+
'}\n';

View File

@ -7,11 +7,11 @@ es5id: 10.2.3_A2.3_T4
description: Global execution context - Other Properties
---*/
var evalStr =
var evalStr =
'//CHECK#1\n'+
'for (var x in this) {\n'+
' if ( x === \'Math\' ) {\n'+
' $ERROR("#1: \'Math\' have attribute DontEnum");\n'+
' throw new Test262Error("#1: \'Math\' have attribute DontEnum");\n'+
' }\n'+
'}\n';