Bug 1368595 part 2 - Rewrite bug1355573.js jit-test to work around the harness not supporting error + allow-oom. r=jonco

This commit is contained in:
Jan de Mooij 2017-06-02 18:36:51 +02:00
Родитель e700643daf
Коммит ab86f7bf5d
1 изменённых файлов: 9 добавлений и 3 удалений

Просмотреть файл

@ -1,6 +1,12 @@
// |jit-test| error:overflow; allow-oom
// |jit-test| allow-oom
if (getBuildConfiguration().debug === true)
throw "overflow";
quit(0);
function f(){};
Object.defineProperty(f, "name", {value: "a".repeat((1<<28)-1)});
len = f.bind().name.length;
var ex = null;
try {
len = f.bind().name.length;
} catch (e) {
ex = e;
}
assertEq(ex instanceof InternalError, true);