Auto merge of #18360 - emilio:test-stuff, r=nox

script: Add a test for #18357

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/18360)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2017-09-03 15:16:19 -05:00 committed by GitHub
commit 7dcd7260a9
2 changed files with 25 additions and 0 deletions

View file

@ -14240,6 +14240,12 @@
{}
]
],
"mozilla/link_rel_crash.html": [
[
"/_mozilla/mozilla/link_rel_crash.html",
{}
]
],
"mozilla/load_event.html": [
[
"/_mozilla/mozilla/load_event.html",
@ -27315,6 +27321,10 @@
"7715f917a07be2a0889be075f5e579fb338d2a31",
"testharness"
],
"mozilla/link_rel_crash.html": [
"a2ca46f6440e851fc646e98455f23efab36c25c7",
"testharness"
],
"mozilla/load_event.html": [
"851eed264ee9ba5902ac9d545bebfbad8a0f4dcc",
"testharness"

View file

@ -0,0 +1,15 @@
<!doctype html>
<meta charset="utf-8">
<title>Test for #18357: Panic after setting the rel attribute of a link element with setAttributeNode.</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
test(function() {
var link = document.createElement("link");
var rel = document.createAttribute("rel");
rel.value = "stylesheet";
link.setAttributeNode(rel);
link.setAttribute("href", "foo");
document.head.appendChild(link);
}, "Doesn't crash when doing setAttributeNode on the rel attribute");
</script>