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

Unified Diff: third_party/WebKit/LayoutTests/fast/css/setting-style-attribute-update-inline-style.html

Issue 1384973004: Forward assigning to style on HTMLElement, SVGElement and CSSStyleRule to style.cssText (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add expectation files Created 5 years, 2 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
Index: third_party/WebKit/LayoutTests/fast/css/setting-style-attribute-update-inline-style.html
diff --git a/third_party/WebKit/LayoutTests/fast/css/setting-style-attribute-update-inline-style.html b/third_party/WebKit/LayoutTests/fast/css/setting-style-attribute-update-inline-style.html
new file mode 100644
index 0000000000000000000000000000000000000000..dd57123e6c8d2efac4b6147f79e6b749351b268b
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/css/setting-style-attribute-update-inline-style.html
@@ -0,0 +1,17 @@
+<script src="../../resources/testharness.js"></script>
+
+<div style="background-color: red">Test</div>
+<div style="background-color: red">Test</div>
+<div style="background-color: red">Test</div>
+
+<script>
+var elements = document.querySelectorAll('div');
+elements[0].style = '';
+elements[1].style.backgroundColor = '';
+elements[2].style = 'color:green';
+
+assert_equals(elements[0].style.backgroundColor, "");
+assert_equals(elements[1].style.backgroundColor, "");
+assert_equals(elements[2].style.backgroundColor, "");
+assert_equals(elements[2].style.color, "green");
+</script>

Powered by Google App Engine
This is Rietveld 408576698