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

Side by Side Diff: third_party/WebKit/LayoutTests/typedcssom/cssKeywordValue.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 <script src='../resources/testharness.js'></script> 2 <script src='../resources/testharness.js'></script>
3 <script src='../resources/testharnessreport.js'></script> 3 <script src='../resources/testharnessreport.js'></script>
4 <script> 4 <script>
5 5
6 test(function() { 6 test(function() {
7 assert_throws(TypeError(), function() { new CSSKeywordValue("") }); 7 assert_throws(TypeError(), function() { new CSSKeywordValue("") });
8 }, "Constructor should throw an error if given an empty string"); 8 }, "Constructor should throw an error if given an empty string");
9 9
10 test(function() { 10 test(function() {
11 assert_equals(new CSSKeywordValue('initial').cssString, 'initial'); 11 assert_equals(new CSSKeywordValue('initial').cssText, 'initial');
12 assert_equals(new CSSKeywordValue('center').cssString, 'center'); 12 assert_equals(new CSSKeywordValue('center').cssText, 'center');
13 assert_equals(new CSSKeywordValue('customLemon').cssString, 'customLemon'); 13 assert_equals(new CSSKeywordValue('customLemon').cssText, 'customLemon');
14 assert_equals(new CSSKeywordValue(' Hello World').cssString, CSS.escape(' Hell o World')); 14 assert_equals(new CSSKeywordValue(' Hello World').cssText, CSS.escape(' Hello World'));
15 assert_equals(new CSSKeywordValue('3').cssString, CSS.escape('3')); 15 assert_equals(new CSSKeywordValue('3').cssText, CSS.escape('3'));
16 }, 'cssString returns a string with a format similar to CSS.escape. This test al so ' + 16 }, 'cssText returns a string with a format similar to CSS.escape. This test also ' +
17 'implies that toCSSValue supports all keywords including custom identifiers' ); 17 'implies that toCSSValue supports all keywords including custom identifiers' );
18 18
19 test(function() { 19 test(function() {
20 assert_equals(new CSSKeywordValue('initial').keywordValue, 'initial'); 20 assert_equals(new CSSKeywordValue('initial').keywordValue, 'initial');
21 assert_equals(new CSSKeywordValue('center').keywordValue, 'center'); 21 assert_equals(new CSSKeywordValue('center').keywordValue, 'center');
22 assert_equals(new CSSKeywordValue('customLemon').keywordValue, 'customLemon'); 22 assert_equals(new CSSKeywordValue('customLemon').keywordValue, 'customLemon');
23 assert_equals(new CSSKeywordValue(' Hello World').keywordValue, ' Hello World' ); 23 assert_equals(new CSSKeywordValue(' Hello World').keywordValue, ' Hello World' );
24 assert_equals(new CSSKeywordValue('3').keywordValue, '3'); 24 assert_equals(new CSSKeywordValue('3').keywordValue, '3');
25 }, 'keywordValue returns a string equal to the string used in the constructor'); 25 }, 'keywordValue returns a string equal to the string used in the constructor');
26 26
27 </script> 27 </script>
28 <body> 28 <body>
29 </body> 29 </body>
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/typedcssom/cssCalcLength.html ('k') | third_party/WebKit/LayoutTests/typedcssom/cssMatrix.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698