Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / svg / custom / bbox-of-g-in-symbol.svg
bloba3aec186d6c0a5be4b99b329d7b0780e938bb694
1 <?xml version="1.0" standalone="no"?>
2 <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.0" width="800" height="600">
3 <symbol>
4 <g id="g0">
5 <rect width="50" height="100" fill="green" />
6 </g>
7 </symbol>
8 <text id="console" x="10" y="20" />
9 <script><![CDATA[
10 if (window.testRunner)
11 testRunner.dumpAsText();
13 function runTest()
15 var bbox = document.getElementById("g0").getBBox();
16 var console = document.getElementById("console");
17 if (bbox.width == 50 && bbox.height == 100) {
18 console.setAttribute("fill", "green");
19 console.appendChild(document.createTextNode("PASS: Right width and height of bbox of rect within symbol."));
20 } else {
21 console.setAttribute("fill", "red");
22 console.appendChild(document.createTextNode("FAIL: Wrong width and/or height of bbox of rect within symbol."));
26 window.onload = runTest();
27 ]]></script>
28 </svg>