Index: third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-setEmptyString.html |
diff --git a/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-setEmptyString.html b/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-setEmptyString.html |
index f808d36638bbc14aed1ec5da6b44011a10e999b1..78f579bbb1a146d1cb820801029351b2613c4567 100644 |
--- a/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-setEmptyString.html |
+++ b/third_party/WebKit/LayoutTests/svg/dom/SVGLengthList-setEmptyString.html |
@@ -1,20 +1,22 @@ |
<!DOCTYPE HTML> |
-<svg id="svg" xmlns="http://www.w3.org/2000/svg" width="200" height="200"> |
+<title>SVGLengthList, set empty string</title> |
+<script src="../../resources/testharness.js"></script> |
+<script src="../../resources/testharnessreport.js"></script> |
+<svg width="200" height="200"> |
<text></text> |
</svg> |
-<script src="../../resources/js-test.js"></script> |
<script> |
-if (window.testRunner) |
- testRunner.dumpAsText(); |
+test(function() { |
+ var text = document.querySelector('text'); |
+ var list = text.x.baseVal; |
+ text.setAttribute("x", "1 2 3"); |
+ assert_equals(list.numberOfItems, 3); |
+ text.setAttribute("x", ""); |
+ assert_equals(list.numberOfItems, 0); |
-var text = document.querySelector('text'); |
-text.setAttribute("x", "1 2 3"); |
-shouldBe("text.x.baseVal.numberOfItems", "3"); |
-text.setAttribute("x", ""); |
-shouldBe("text.x.baseVal.numberOfItems", "0"); |
- |
-text.setAttribute("x", "1 2 3"); |
-shouldBe("text.x.baseVal.numberOfItems", "3"); |
-text.removeAttribute("x"); |
-shouldBe("text.x.baseVal.numberOfItems", "0"); |
-</script> |
+ text.setAttribute("x", "1 2 3"); |
+ assert_equals(list.numberOfItems, 3); |
+ text.removeAttribute("x"); |
+ assert_equals(list.numberOfItems, 0); |
+}); |
+</script> |