blob: 15aaaf7801655434847a66e8dda7eda29b54efd1 (
plain)
1
2
3
4
5
6
7
8
9
|
var caught = false;
try {
Reflect.parse("}");
} catch (e) {
assertEq(e instanceof SyntaxError, true);
assertEq(e.message.startsWith("unexpected garbage after script, starting with '}'") == -1, false);
caught = true;
}
assertEq(caught, true);
|