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

Side by Side Diff: base/mac/mac_util_unittest.mm

Issue 9701031: Add preliminary OOM support for Mountain Lion. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: tweak comments Created 8 years, 9 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 | « base/mac/mac_util.mm ('k') | base/process_util_mac.mm » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #import <Cocoa/Cocoa.h> 5 #import <Cocoa/Cocoa.h>
6 6
7 #include "base/mac/mac_util.h" 7 #include "base/mac/mac_util.h"
8 8
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 EXPECT_FALSE(IsOSSnowLeopard()); 157 EXPECT_FALSE(IsOSSnowLeopard());
158 EXPECT_TRUE(IsOSSnowLeopardOrEarlier()); 158 EXPECT_TRUE(IsOSSnowLeopardOrEarlier());
159 EXPECT_FALSE(IsOSSnowLeopardOrLater()); 159 EXPECT_FALSE(IsOSSnowLeopardOrLater());
160 EXPECT_FALSE(IsOSLion()); 160 EXPECT_FALSE(IsOSLion());
161 EXPECT_TRUE(IsOSLionOrEarlier()); 161 EXPECT_TRUE(IsOSLionOrEarlier());
162 EXPECT_FALSE(IsOSLionOrLater()); 162 EXPECT_FALSE(IsOSLionOrLater());
163 EXPECT_FALSE(IsOSMountainLion()); 163 EXPECT_FALSE(IsOSMountainLion());
164 EXPECT_FALSE(IsOSMountainLionOrLater()); 164 EXPECT_FALSE(IsOSMountainLionOrLater());
165 EXPECT_FALSE( 165 EXPECT_FALSE(
166 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement()); 166 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
167 EXPECT_FALSE(IsOSLaterThanLion());
168 } else if (minor == 6) { 167 } else if (minor == 6) {
169 EXPECT_FALSE(IsOSLeopard()); 168 EXPECT_FALSE(IsOSLeopard());
170 EXPECT_FALSE(IsOSLeopardOrEarlier()); 169 EXPECT_FALSE(IsOSLeopardOrEarlier());
171 EXPECT_TRUE(IsOSSnowLeopard()); 170 EXPECT_TRUE(IsOSSnowLeopard());
172 EXPECT_TRUE(IsOSSnowLeopardOrEarlier()); 171 EXPECT_TRUE(IsOSSnowLeopardOrEarlier());
173 EXPECT_TRUE(IsOSSnowLeopardOrLater()); 172 EXPECT_TRUE(IsOSSnowLeopardOrLater());
174 EXPECT_FALSE(IsOSLion()); 173 EXPECT_FALSE(IsOSLion());
175 EXPECT_TRUE(IsOSLionOrEarlier()); 174 EXPECT_TRUE(IsOSLionOrEarlier());
176 EXPECT_FALSE(IsOSLionOrLater()); 175 EXPECT_FALSE(IsOSLionOrLater());
177 EXPECT_FALSE(IsOSMountainLion()); 176 EXPECT_FALSE(IsOSMountainLion());
178 EXPECT_FALSE(IsOSMountainLionOrLater()); 177 EXPECT_FALSE(IsOSMountainLionOrLater());
179 EXPECT_FALSE( 178 EXPECT_FALSE(
180 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement()); 179 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
181 EXPECT_FALSE(IsOSLaterThanLion());
182 } else if (minor == 7) { 180 } else if (minor == 7) {
183 EXPECT_FALSE(IsOSLeopard()); 181 EXPECT_FALSE(IsOSLeopard());
184 EXPECT_FALSE(IsOSLeopardOrEarlier()); 182 EXPECT_FALSE(IsOSLeopardOrEarlier());
185 EXPECT_FALSE(IsOSSnowLeopard()); 183 EXPECT_FALSE(IsOSSnowLeopard());
186 EXPECT_FALSE(IsOSSnowLeopardOrEarlier()); 184 EXPECT_FALSE(IsOSSnowLeopardOrEarlier());
187 EXPECT_TRUE(IsOSSnowLeopardOrLater()); 185 EXPECT_TRUE(IsOSSnowLeopardOrLater());
188 EXPECT_TRUE(IsOSLion()); 186 EXPECT_TRUE(IsOSLion());
189 EXPECT_TRUE(IsOSLionOrEarlier()); 187 EXPECT_TRUE(IsOSLionOrEarlier());
190 EXPECT_TRUE(IsOSLionOrLater()); 188 EXPECT_TRUE(IsOSLionOrLater());
191 EXPECT_FALSE(IsOSMountainLion()); 189 EXPECT_FALSE(IsOSMountainLion());
192 EXPECT_FALSE(IsOSMountainLionOrLater()); 190 EXPECT_FALSE(IsOSMountainLionOrLater());
193 EXPECT_FALSE( 191 EXPECT_FALSE(
194 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement()); 192 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
195 } else if (minor == 8) { 193 } else if (minor == 8) {
196 EXPECT_FALSE(IsOSLeopard()); 194 EXPECT_FALSE(IsOSLeopard());
197 EXPECT_FALSE(IsOSLeopardOrEarlier()); 195 EXPECT_FALSE(IsOSLeopardOrEarlier());
198 EXPECT_FALSE(IsOSSnowLeopard()); 196 EXPECT_FALSE(IsOSSnowLeopard());
199 EXPECT_FALSE(IsOSSnowLeopardOrEarlier()); 197 EXPECT_FALSE(IsOSSnowLeopardOrEarlier());
200 EXPECT_TRUE(IsOSSnowLeopardOrLater()); 198 EXPECT_TRUE(IsOSSnowLeopardOrLater());
201 EXPECT_FALSE(IsOSLion()); 199 EXPECT_FALSE(IsOSLion());
202 EXPECT_FALSE(IsOSLionOrEarlier()); 200 EXPECT_FALSE(IsOSLionOrEarlier());
203 EXPECT_TRUE(IsOSLionOrLater()); 201 EXPECT_TRUE(IsOSLionOrLater());
204 EXPECT_TRUE(IsOSMountainLion()); 202 EXPECT_TRUE(IsOSMountainLion());
205 EXPECT_TRUE(IsOSMountainLionOrLater()); 203 EXPECT_TRUE(IsOSMountainLionOrLater());
206 EXPECT_FALSE( 204 EXPECT_FALSE(
207 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement()); 205 IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
208 EXPECT_TRUE(IsOSLaterThanLion());
209 } else { 206 } else {
210 // Not five, six, seven, or eight. Ah, ah, ah. 207 // Not five, six, seven, or eight. Ah, ah, ah.
211 EXPECT_TRUE(false); 208 EXPECT_TRUE(false);
212 } 209 }
213 } else { 210 } else {
214 // Not ten. What you gonna do? 211 // Not ten. What you gonna do?
215 EXPECT_FALSE(true); 212 EXPECT_FALSE(true);
216 } 213 }
217 } 214 }
218 215
(...skipping 15 matching lines...) Expand all
234 EXPECT_TRUE(ParseModelIdentifier("MacBookPro6,2", &model, &major, &minor)); 231 EXPECT_TRUE(ParseModelIdentifier("MacBookPro6,2", &model, &major, &minor));
235 EXPECT_EQ(model, "MacBookPro"); 232 EXPECT_EQ(model, "MacBookPro");
236 EXPECT_EQ(6, major); 233 EXPECT_EQ(6, major);
237 EXPECT_EQ(2, minor); 234 EXPECT_EQ(2, minor);
238 } 235 }
239 236
240 } // namespace 237 } // namespace
241 238
242 } // namespace mac 239 } // namespace mac
243 } // namespace base 240 } // namespace base
OLDNEW
« no previous file with comments | « base/mac/mac_util.mm ('k') | base/process_util_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698