Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / svg / foreignObject / invalid-svg-child-renderer.html
blob9d1cae2e7cd7d111d25043175cf72a1a7e37f89f
1 <!DOCTYPE html>
2 <html>
3 <body>
4 <div id="container"></div>
6 PASS: test did not crash.
8 <script>
9 /* Build the following shadow tree structure to verify that <svg> elements always
10 * receive a LayoutSVGRoot renderer when their parent is <foreignObject>:
11 * <svg>
12 * <foreignObject>
13 * <svg></svg>
14 * </foreignObject>
15 * </svg>
17 function create_shadow() {
18 var root = document.getElementById('container').createShadowRoot();
19 var svg1 = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
20 root.appendChild(svg1);
21 var fo = document.createElementNS('http://www.w3.org/2000/svg', 'foreignObject');
22 svg1.appendChild(fo);
23 var svg2 = document.createElementNS('http://www.w3.org/2000/svg', 'svg');
24 fo.appendChild(svg2);
27 if (window.testRunner) {
28 create_shadow();
29 testRunner.dumpAsText();
31 </script>
32 </body>
33 </html>