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

Unified Diff: third_party/WebKit/LayoutTests/typedcssom/computedstyle/border-top-width.html

Issue 1849653003: Implement ComputedStylePropertyMap for Typed OM. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@maps-inline
Patch Set: Update LayoutTests Created 4 years, 6 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 | third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/typedcssom/computedstyle/border-top-width.html
diff --git a/third_party/WebKit/LayoutTests/typedcssom/computedstyle/border-top-width.html b/third_party/WebKit/LayoutTests/typedcssom/computedstyle/border-top-width.html
new file mode 100644
index 0000000000000000000000000000000000000000..97b7e56a77492671cec54865627e73d2bd499090
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/typedcssom/computedstyle/border-top-width.html
@@ -0,0 +1,27 @@
+<!DOCTYPE html>
+<script src='../../resources/testharness.js'></script>
+<script src='../../resources/testharnessreport.js'></script>
+
+<div id="testElement"></div>
+
+<script>
+
+var computedStyleMap = getComputedStyleMap(testElement);
+
+test(function() {
+ testElement.style.borderTop = '10px solid #000';
+
+ var result = computedStyleMap.get('border-top-width');
+ assert_true(result instanceof CSSSimpleLength);
+ assert_equals(result.cssString, '10px');
+}, "Getting a 10px border-top-width returns a CSSSimpleLength");
+
+test(function() {
+ testElement.style.borderTop = '20px solid #000';
+
+ var result = computedStyleMap.getAll('border-top-width');
+ assert_equals(result.length, 1);
+ assert_equals(result[0].cssString, '20px');
+}, "getAll for border-top-width returns a single value");
+
+</script>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/typedcssom/computedstyle/computedStylePropertyMap.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698