Home | History | Annotate | Download | only in HTMLHtmlElement
      1 <html version="1">
      2 <body>
      3 <p>
      4 This tests to make sure that HTMLHtmlElement::version settable.</p>
      5 You should see 2 lines with "SUCCESS" below:
      6 <script>
      7 if (window.layoutTestController)
      8     layoutTestController.dumpAsText();
      9 
     10 function checkExpected(actual, expected)
     11 {
     12     if (actual != expected)
     13         document.writeln("<p>FAILURE: expected \"" + expected + "\", actual \"" + actual + "\"</p>");
     14     else
     15         document.writeln("<p>SUCCESS (value: \"" + actual + "\")</p>");
     16 }
     17 
     18 var htmlElement = document.getElementsByTagName("html")[0];
     19 checkExpected(htmlElement.version, 1);
     20 htmlElement.version = 2;
     21 checkExpected(htmlElement.version, 2);
     22 </script>
     23 </body>
     24 </html>