Index: third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg |
diff --git a/third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg b/third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg |
new file mode 100644 |
index 0000000000000000000000000000000000000000..da5e169b4f86bec62faac53855429bdf7a96f8a7 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/svg/css/cursor-change-href.svg |
@@ -0,0 +1,32 @@ |
+<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> |
+ <g style="cursor:url(#cursor), auto"> |
+ <g> |
+ <rect id="rect" x="50" y="50" width="100" height="100" fill="green" /> |
+ <text id="result1" x="50" y="200">Not run.</text> |
+ <text id="result2" x="50" y="220">Not run.</text> |
+ </g> |
+ </g> |
+ <cursor id="cursor" xlink:href="file:///icon1.ico" x="0" y="0" /> |
+ <script> |
+ // Modifying href of a cursor element should cause a recalc of elements using it. |
+ |
+ if (window.testRunner) |
+ testRunner.dumpAsText(); |
+ |
+ var rect = document.getElementById("rect"); |
+ var result1 = document.getElementById("result1").firstChild; |
+ var result2 = document.getElementById("result2").firstChild; |
+ |
+ if (getComputedStyle(rect).cursor == "url(\"file:///icon1.ico\"), auto") |
+ result1.data = "PASS"; |
+ else |
+ result1.data = "FAIL - " + getComputedStyle(rect).cursor; |
+ |
+ document.getElementById("cursor").setAttribute("xlink:href", "file:///icon2.ico"); |
+ |
+ if (getComputedStyle(rect).cursor == "url(\"file:///icon2.ico\"), auto") |
+ result2.data = "PASS"; |
+ else |
+ result2.data = "FAIL - " + getComputedStyle(rect).cursor; |
+ </script> |
+</svg> |