mirror of https://github.com/tc39/test262.git
Fix several Decode tests (#1357)
The tests are explicitly for bad hex chars at certain indexes, and that rogue `%` was giving false positives.
This commit is contained in:
parent
1702336a77
commit
da61938f8f
|
@ -20,7 +20,7 @@ var interval = [[0x00, 0x29], [0x40,0x40], [0x47, 0x60], [0x67, 0xFFFF]];
|
|||
for (var indexI = 0; indexI < interval.length; indexI++) {
|
||||
for (var indexJ = interval[indexI][0]; indexJ <= interval[indexI][1]; indexJ++) {
|
||||
try {
|
||||
decodeURI("%E0%" + "%A0" + String.fromCharCode(indexJ, indexJ));
|
||||
decodeURI("%E0" + "%A0%" + String.fromCharCode(indexJ, indexJ));
|
||||
result = false;
|
||||
} catch (e) {
|
||||
if ((e instanceof URIError) !== true) {
|
||||
|
|
|
@ -21,7 +21,7 @@ var interval = [[0x00, 0x29], [0x40,0x40], [0x47, 0x60], [0x67, 0xFFFF]];
|
|||
for (var indexI = 0; indexI < interval.length; indexI++) {
|
||||
for (var indexJ = interval[indexI][0]; indexJ <= interval[indexI][1]; indexJ++) {
|
||||
try {
|
||||
decodeURI("%F0%" + "%A0" + String.fromCharCode(indexJ, indexJ) + "%A0");
|
||||
decodeURI("%F0" + "%A0%" + String.fromCharCode(indexJ, indexJ) + "%A0");
|
||||
result = false;
|
||||
} catch (e) {
|
||||
if ((e instanceof URIError) !== true) {
|
||||
|
|
|
@ -21,7 +21,7 @@ var interval = [[0x00, 0x29], [0x40,0x40], [0x47, 0x60], [0x67, 0xFFFF]];
|
|||
for (var indexI = 0; indexI < interval.length; indexI++) {
|
||||
for (var indexJ = interval[indexI][0]; indexJ <= interval[indexI][1]; indexJ++) {
|
||||
try {
|
||||
decodeURI("%F0%" + "%A0%A0" + String.fromCharCode(indexJ, indexJ));
|
||||
decodeURI("%F0" + "%A0%A0%" + String.fromCharCode(indexJ, indexJ));
|
||||
result = false;
|
||||
} catch (e) {
|
||||
if ((e instanceof URIError) !== true) {
|
||||
|
|
|
@ -20,7 +20,7 @@ var interval = [[0x00, 0x29], [0x40,0x40], [0x47, 0x60], [0x67, 0xFFFF]];
|
|||
for (var indexI = 0; indexI < interval.length; indexI++) {
|
||||
for (var indexJ = interval[indexI][0]; indexJ <= interval[indexI][1]; indexJ++) {
|
||||
try {
|
||||
decodeURIComponent("%E0%" + "%A0" + String.fromCharCode(indexJ, indexJ));
|
||||
decodeURIComponent("%E0" + "%A0%" + String.fromCharCode(indexJ, indexJ));
|
||||
result = false;
|
||||
} catch (e) {
|
||||
if ((e instanceof URIError) !== true) {
|
||||
|
|
|
@ -21,7 +21,7 @@ var interval = [[0x00, 0x29], [0x40,0x40], [0x47, 0x60], [0x67, 0xFFFF]];
|
|||
for (var indexI = 0; indexI < interval.length; indexI++) {
|
||||
for (var indexJ = interval[indexI][0]; indexJ <= interval[indexI][1]; indexJ++) {
|
||||
try {
|
||||
decodeURIComponent("%F0%" + "%A0" + String.fromCharCode(indexJ, indexJ) + "%A0");
|
||||
decodeURIComponent("%F0" + "%A0%" + String.fromCharCode(indexJ, indexJ) + "%A0");
|
||||
result = false;
|
||||
} catch (e) {
|
||||
if ((e instanceof URIError) !== true) {
|
||||
|
|
|
@ -21,7 +21,7 @@ var interval = [[0x00, 0x29], [0x40,0x40], [0x47, 0x60], [0x67, 0xFFFF]];
|
|||
for (var indexI = 0; indexI < interval.length; indexI++) {
|
||||
for (var indexJ = interval[indexI][0]; indexJ <= interval[indexI][1]; indexJ++) {
|
||||
try {
|
||||
decodeURIComponent("%F0%" + "%A0%A0" + String.fromCharCode(indexJ, indexJ));
|
||||
decodeURIComponent("%F0" + "%A0%A0%" + String.fromCharCode(indexJ, indexJ));
|
||||
result = false;
|
||||
} catch (e) {
|
||||
if ((e instanceof URIError) !== true) {
|
||||
|
|
Loading…
Reference in New Issue