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

Side by Side Diff: third_party/WebKit/LayoutTests/typedcssom/computedstyle/pseudo-elements.html

Issue 2097093002: [Typed OM] Rename cssString methods to cssText (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@rename-transformvalue
Patch Set: Update usage in csspaint logging for tests Created 4 years, 5 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 unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 2
3 <script src='../../resources/testharness.js'></script> 3 <script src='../../resources/testharness.js'></script>
4 <script src='../../resources/testharnessreport.js'></script> 4 <script src='../../resources/testharnessreport.js'></script>
5 5
6 <style> 6 <style>
7 #testElement { 7 #testElement {
8 border: 5px solid purple; 8 border: 5px solid purple;
9 } 9 }
10 10
11 #testElement:after { 11 #testElement:after {
12 border: 1px solid black; 12 border: 1px solid black;
13 } 13 }
14 </style> 14 </style>
15 15
16 <div id="testElement"></div> 16 <div id="testElement"></div>
17 17
18 <script> 18 <script>
19 19
20 var computedStyleMap = getComputedStyleMap(testElement); 20 var computedStyleMap = getComputedStyleMap(testElement);
21 var pseudoComputedStyleMap = getComputedStyleMap(testElement, '::after'); 21 var pseudoComputedStyleMap = getComputedStyleMap(testElement, '::after');
22 test(function() { 22 test(function() {
23 assert_equals(computedStyleMap.get('border-top-width').cssString, '5px'); 23 assert_equals(computedStyleMap.get('border-top-width').cssText, '5px');
24 assert_equals(pseudoComputedStyleMap.get('border-top-width').cssString, '1px') ; 24 assert_equals(pseudoComputedStyleMap.get('border-top-width').cssText, '1px');
25 }, 'get on Computed StyleMap of pseudo element returns correct styles'); 25 }, 'get on Computed StyleMap of pseudo element returns correct styles');
26 26
27 test(function() { 27 test(function() {
28 // TODO(meade): When actual multiple valued properties are supported, use one of them. 28 // TODO(meade): When actual multiple valued properties are supported, use one of them.
29 29
30 var styleValueList = pseudoComputedStyleMap.getAll('border-top-width'); 30 var styleValueList = pseudoComputedStyleMap.getAll('border-top-width');
31 assert_equals(styleValueList.length, 1); 31 assert_equals(styleValueList.length, 1);
32 assert_equals(styleValueList[0].cssString, '1px'); 32 assert_equals(styleValueList[0].cssText, '1px');
33 }, 'getAll on Computed StyleMap of pseudo element returns list of correct styles '); 33 }, 'getAll on Computed StyleMap of pseudo element returns list of correct styles ');
34 34
35 </script> 35 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698