Chromium Code Reviews| Index: LayoutTests/fast/dom/relList_on_link.html |
| diff --git a/LayoutTests/fast/dom/relList_on_link.html b/LayoutTests/fast/dom/relList_on_link.html |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..4b7563a8877e7887631b483dcf4bbea5b4b62e3d |
| --- /dev/null |
| +++ b/LayoutTests/fast/dom/relList_on_link.html |
| @@ -0,0 +1,21 @@ |
| +<link id="linkId" rel="shortcut icon" href="../images/resources/1bit.ico"/> |
|
Inactive
2014/07/25 12:55:51
Please add back the DOCTYPE.
|
| +<script src="../../resources/js-test.js"></script> |
| +<script> |
| +description("Checks relList attribute on link element"); |
| + |
| +var link = document.getElementById('linkId'); |
| +shouldBe("link.relList.__proto__", "DOMTokenList.prototype"); |
| +shouldBeTrue("link.relList.contains('shortcut')"); |
|
Inactive
2014/07/25 12:55:51
Same comment about using indexed getter.
|
| +shouldBeTrue("link.relList.contains('icon')"); |
| +shouldBe("link.relList.length", "2"); |
| +shouldBeFalse("link.relList.contains('shortcut1')"); |
| +shouldNotThrow("link.rel = 'nofollow'"); |
| +shouldBe("link.relList.length", "1"); |
| +shouldBeTrue("link.relList.contains('nofollow')"); |
| +shouldBeFalse("link.relList.contains('shortcut')"); |
| +shouldBeFalse("link.relList.contains('icon')"); |
| +shouldNotThrow("link.removeAttribute('rel')"); |
| +shouldBeEmptyString("link.rel"); |
| +shouldBe("link.relList.length", "0"); |
| +shouldBeUndefined("link.relList[0]"); |
| +</script> |