test-012.html (1046B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <title>Shadow DOM Test: A_10_01_01_06</title> 5 <link rel="author" title="Sergey G. Grekhov" href="mailto:sgrekhov@unipro.ru"> 6 <link rel="help" href="http://www.w3.org/TR/2013/WD-shadow-dom-20130514/#shadow-root-attributes"> 7 <meta name="assert" content="ShadowRoot Object: The nodeType attribute of a ShadowRoot instance must return DOCUMENT_FRAGMENT_NODE"> 8 <script src="/resources/testharness.js"></script> 9 <script src="/resources/testharnessreport.js"></script> 10 <script src="../../../../../html/resources/common.js"></script> 11 <script src="../../../../resources/shadow-dom-utils.js"></script> 12 </head> 13 <body> 14 <div id="log"></div> 15 <script> 16 test(unit(function (ctx) { 17 18 var d = newRenderedHTMLDocument(ctx); 19 20 var host = d.createElement('div'); 21 d.body.appendChild(host); 22 var s = host.attachShadow({mode: 'open'}); 23 24 assert_equals(s.nodeType, 11, 'The nodeType attribute of a ShadowRoot ' + 25 'instance must return DOCUMENT_FRAGMENT_NODE'); 26 27 }), 'A_10_01_01_06_T01'); 28 </script> 29 </body> 30 </html>