Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(125)

Unified Diff: LayoutTests/fast/svg/linear-gradient-default-length.html

Issue 1083893002: The default for x1, y1 and y2 is 0% for LinearGradient (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Align with review comments Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/svg/SVGLinearGradientElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/svg/linear-gradient-default-length.html
diff --git a/LayoutTests/fast/svg/linear-gradient-default-length.html b/LayoutTests/fast/svg/linear-gradient-default-length.html
new file mode 100644
index 0000000000000000000000000000000000000000..f3d9d3799caaaea3beb2cde7262f68a682b3a7b9
--- /dev/null
+++ b/LayoutTests/fast/svg/linear-gradient-default-length.html
@@ -0,0 +1,20 @@
+<!doctype html>
+<title>SVGLinearGradientElement coordinate defaults</title>
+<script src=../../resources/testharness.js></script>
+<script src=../../resources/testharnessreport.js></script>
+<svg>
+ <linearGradient id="lg"/>
+</svg>
+<script>
+function testLengthValue(result, expected, testcase) {
+ test(function() {
+ assert_equals(result, expected);
+ }, "Testing " + document.title + " " + testcase);
+}
+
+var linearGradient = document.querySelector("#lg");
+testLengthValue(linearGradient.x1.baseVal.valueAsString, "0%", "x1");
+testLengthValue(linearGradient.x2.baseVal.valueAsString, "100%", "x2");
+testLengthValue(linearGradient.y1.baseVal.valueAsString, "0%", "y1");
+testLengthValue(linearGradient.y2.baseVal.valueAsString, "0%", "y2");
+</script>
« no previous file with comments | « no previous file | Source/core/svg/SVGLinearGradientElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698