Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / namednodemap-namelookup.html
blob30e42f4ab25446d75ca8c75ef6a193b6e3be2ce6
1 <html>
2 <body>
3 <div id="div" name="divname" item="canoveride"></div>
4 <pre>
5 <script>
6 if (window.testRunner) {
7 testRunner.dumpAsText();
9 var hadError = false;
10 var myDiv = document.getElementById("div");
11 var attribute = myDiv.attributes["name"];
12 if (attribute != "[object Attr]") {
13 document.writeln('ERROR: attributes["name"] should be an attribute object: ' + attribute);
14 hadError = true;
17 attribute = myDiv.attributes["item"];
18 if (attribute.value) {
19 document.writeln('ERROR: attributes["item"].value : ' + attribute.value);
20 hadError = true;
23 if (!hadError)
24 document.writeln("Success");
26 </script>
27 </pre>
28 </body>
29 </html>