Bug 1561163 [wpt PR 17452] - Improve failing condition of a test., a=testonly

Automatic update from web-platform-tests
Improve failing condition of a test (#17452)

So it doesn't time out.
--

wpt-commits: 1f512077ca0998e0af60ff727eea8c8ba5d78491
wpt-pr: 17452
This commit is contained in:
Emilio Cobos Álvarez 2019-07-19 14:02:25 +00:00 коммит произвёл James Graham
Родитель d7cb05044a
Коммит 019c28cf0f
1 изменённых файлов: 4 добавлений и 1 удалений

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

@ -7,6 +7,9 @@
<div id="host"></div>
<script>
let svgScript = document.createElementNS("http://www.w3.org/2000/svg", "script");
svgScript.innerHTML = `test(function() {}, "svg:script runs correctly in a shadow tree");`;
svgScript.innerHTML = "window.scriptRan = true";
document.getElementById("host").attachShadow({ mode: "open" }).appendChild(svgScript);
test(function() {
assert_true(window.scriptRan);
}, "svg:script runs correctly in a shadow tree");
</script>