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

Unified Diff: third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html

Issue 2791193004: [Typed CSSOM] New design for computed styles which includes custom properties (Closed)
Patch Set: replace node check with dcheck Created 3 years, 7 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/typedcssom/computedstyle/computedStylePropertyMap.html
diff --git a/third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html b/third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html
index 8f3fb6dba26f5fa9b5523ff197c8693b0773f661..7755f5bfb019ef451c6d5ab010e1ee47c6a9f72f 100644
--- a/third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html
+++ b/third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html
@@ -37,7 +37,11 @@ test(function() {
}, 'Unsupported and unserializable property returns null.');
test(function() {
- assert_false(computedStyleMap.has('max-zoom'));
+ assert_throws(null, function() { computedStyleMap.get('bananas'); });
+}, 'get() throws for an invalid property.');
+
+test(function() {
+ assert_false(computedStyleMap.has('-webkit-mask'));
}, 'has() return false for an unsupported property.');
test(function() {
@@ -59,4 +63,11 @@ test(function() {
assert_true(computedStyleMap.has('width'));
}, 'has() returns true for a supported property.');
+test(function() {
+ testElement.style.width = '100px';
+ assert_equals(computedStyleMap.get('width').cssText, '100px');
+ testElement.style.display = 'none';
+ assert_equals(computedStyleMap.get('width').cssText, '100px');
+}, 'get() returns correct values for an element with display: none.');
+
</script>

Powered by Google App Engine
This is Rietveld 408576698