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

This commit is contained in:
Rick Waldron 2021-07-29 14:02:59 -04:00 committed by GitHub
parent 8c3753020a
commit 5ab89bbb55
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 5 deletions

View File

@ -30,11 +30,11 @@ for (var index = 0; index <= 65535; index++) {
if ((indexP - indexO) !== 0) {
var hexP = decimalToHexString(indexP);
var hexO = decimalToHexString(indexO);
$ERROR('#' + hexO + '-' + hexP + ' ');
throw new Test262Error('#' + hexO + '-' + hexP + ' ');
}
else {
var hexP = decimalToHexString(indexP);
$ERROR('#' + hexP + ' ');
throw new Test262Error('#' + hexP + ' ');
}
indexO = index;
}
@ -50,10 +50,10 @@ if (errorCount > 0) {
if ((indexP - indexO) !== 0) {
var hexP = decimalToHexString(indexP);
var hexO = decimalToHexString(indexO);
$ERROR('#' + hexO + '-' + hexP + ' ');
throw new Test262Error('#' + hexO + '-' + hexP + ' ');
} else {
var hexP = decimalToHexString(indexP);
$ERROR('#' + hexP + ' ');
throw new Test262Error('#' + hexP + ' ');
}
$ERROR('Total error: ' + errorCount + ' bad Unicode character in ' + count + ' ');
throw new Test262Error('Total error: ' + errorCount + ' bad Unicode character in ' + count + ' ');
}