2017-05-11 07:06:41 +00:00
|
|
|
// A SyntaxError leaks to phantom.onError, despite the try-catch.
|
|
|
|
setup({ allow_uncaught_exception: true });
|
|
|
|
|
|
|
|
test(function () {
|
|
|
|
var helperFile = "../fixtures/parse-error-helper.js";
|
|
|
|
try {
|
|
|
|
phantom.injectJs(helperFile);
|
2017-07-23 16:56:35 +00:00
|
|
|
assert_is_true(false);
|
2017-05-11 07:06:41 +00:00
|
|
|
} catch (e) {
|
2017-07-23 16:56:35 +00:00
|
|
|
assert_is_true(e.stack.indexOf('fixtures/parse-error-helper.js:2') !== -1);
|
2017-05-11 07:06:41 +00:00
|
|
|
}
|
|
|
|
}, "stack trace from syntax error in injected file");
|