Index: LayoutTests/fast/svg/SVGStyleElement.html |
diff --git a/LayoutTests/fast/svg/SVGStyleElement.html b/LayoutTests/fast/svg/SVGStyleElement.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..30e6ae53d5061e44020c9b57d565c0744d3da0d4 |
--- /dev/null |
+++ b/LayoutTests/fast/svg/SVGStyleElement.html |
@@ -0,0 +1,31 @@ |
+<!doctype html> |
+<title>SVGStyleElement tests</title> |
+<script src=../../resources/testharness.js></script> |
+<script src=../../resources/testharnessreport.js></script> |
+<div id="testcontainer"> |
+<svg width="1" height="1" visibility="hidden"> |
+<defs><style>.test { fill: green; }</style></defs> |
+</svg> |
+</div> |
+<div id=log></div> |
+<script> |
+var svg = document.querySelector("svg"), |
+ style = document.querySelector("style"); |
+ |
+test(function() { |
+ assert_exists(style, "sheet", ""); |
+}, "SVGStyleElement implements LinkStyle"); |
+ |
+test(function() { |
+ assert_equals(document.styleSheets[0], style.sheet); |
+}, "document.styleSheets contains style.sheet"); |
+ |
+test(function() { |
+ assert_equals(document.styleSheets[0].ownerNode, style); |
+}, "sheet has correct ownerNode #1"); |
+ |
+test(function() { |
+ assert_equals(style.sheet.ownerNode, style); |
+}, "sheet has correct ownerNode #2"); |
+ |
+</script> |