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

Side by Side Diff: Source/core/css/MediaQuerySetTest.cpp

Issue 285643006: Kill WTF::DecimalNumber class (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Inline single-line function Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/css/MediaQueryExp.cpp ('k') | Source/platform/JSONValues.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/css/MediaQuery.h" 6 #include "core/css/MediaQuery.h"
7 7
8 #include "core/css/MediaList.h" 8 #include "core/css/MediaList.h"
9 #include "wtf/PassOwnPtr.h" 9 #include "wtf/PassOwnPtr.h"
10 #include "wtf/text/StringBuilder.h" 10 #include "wtf/text/StringBuilder.h"
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 {"screen and (max-WIDTH: 500px)", "screen and (max-width: 500px)", true} , 87 {"screen and (max-WIDTH: 500px)", "screen and (max-width: 500px)", true} ,
88 {"screen and (max-width: 24.4em)", 0, true}, 88 {"screen and (max-width: 24.4em)", 0, true},
89 {"screen and (max-width: 24.4EM)", "screen and (max-width: 24.4em)", tru e}, 89 {"screen and (max-width: 24.4EM)", "screen and (max-width: 24.4em)", tru e},
90 {"screen and (max-width: blabla)", "not all", true}, 90 {"screen and (max-width: blabla)", "not all", true},
91 {"screen and (max-width: 1)", "not all", true}, 91 {"screen and (max-width: 1)", "not all", true},
92 {"screen and (max-width: 0)", 0, true}, 92 {"screen and (max-width: 0)", 0, true},
93 {"screen and (max-width: 1deg)", "not all", true}, 93 {"screen and (max-width: 1deg)", "not all", true},
94 {"handheld and (min-width: 20em), \nscreen and (min-width: 20em)", "hand held and (min-width: 20em), screen and (min-width: 20em)", true}, 94 {"handheld and (min-width: 20em), \nscreen and (min-width: 20em)", "hand held and (min-width: 20em), screen and (min-width: 20em)", true},
95 {"print and (min-resolution: 300dpi)", 0, true}, 95 {"print and (min-resolution: 300dpi)", 0, true},
96 {"print and (min-resolution: 118dpcm)", 0, true}, 96 {"print and (min-resolution: 118dpcm)", 0, true},
97 {"(resolution: 0.83333333333333333333dppx)", "(resolution: 0.83333333333 33334dppx)", true}, 97 {"(resolution: 0.83333333333333333333dppx)", "(resolution: 0.83333333333 3333dppx)", true},
98 {"(resolution: 2.4dppx)", 0, true}, 98 {"(resolution: 2.4dppx)", 0, true},
99 {"all and(color)", "not all", true}, 99 {"all and(color)", "not all", true},
100 {"all and (", "not all", true}, 100 {"all and (", "not all", true},
101 {"test;,all", "not all, all", true}, 101 {"test;,all", "not all, all", true},
102 {"(color:20example)", "not all", false}, 102 {"(color:20example)", "not all", false},
103 {"not braille", 0, true}, 103 {"not braille", 0, true},
104 {",screen", "not all, screen", true}, 104 {",screen", "not all, screen", true},
105 {",all", "not all, all", true}, 105 {",all", "not all, all", true},
106 {",,all,,", "not all, not all, all, not all, not all", true}, 106 {",,all,,", "not all, not all, all, not all, not all", true},
107 {",,all,, ", "not all, not all, all, not all, not all", true}, 107 {",,all,, ", "not all, not all, all, not all, not all", true},
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 162
163 for (unsigned i = 0; testCases[i].input; ++i) { 163 for (unsigned i = 0; testCases[i].input; ++i) {
164 RefPtrWillBeRawPtr<MediaQuerySet> oldParserQuerySet = MediaQuerySet::cre ate(testCases[i].input); 164 RefPtrWillBeRawPtr<MediaQuerySet> oldParserQuerySet = MediaQuerySet::cre ate(testCases[i].input);
165 RefPtrWillBeRawPtr<MediaQuerySet> threadSafeQuerySet = MediaQuerySet::cr eateOffMainThread(testCases[i].input); 165 RefPtrWillBeRawPtr<MediaQuerySet> threadSafeQuerySet = MediaQuerySet::cr eateOffMainThread(testCases[i].input);
166 testMediaQuery(testCases[i], *oldParserQuerySet, true); 166 testMediaQuery(testCases[i], *oldParserQuerySet, true);
167 testMediaQuery(testCases[i], *threadSafeQuerySet, false); 167 testMediaQuery(testCases[i], *threadSafeQuerySet, false);
168 } 168 }
169 } 169 }
170 170
171 } // namespace 171 } // namespace
OLDNEW
« no previous file with comments | « Source/core/css/MediaQueryExp.cpp ('k') | Source/platform/JSONValues.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698