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

Unified Diff: base/mac/mac_util_unittest.mm

Issue 9706001: [Mac] Add the OS version check functions for 10.8. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/mac/mac_util.mm ('k') | base/process_util_mac.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/mac/mac_util_unittest.mm
diff --git a/base/mac/mac_util_unittest.mm b/base/mac/mac_util_unittest.mm
index 966d8edfe2606d1f7011f2748b938c829a5fb7cf..d7f2b3d18ee780e94048973f9069e65a69bd2a52 100644
--- a/base/mac/mac_util_unittest.mm
+++ b/base/mac/mac_util_unittest.mm
@@ -158,7 +158,12 @@ TEST_F(MacUtilTest, IsOSEllipsis) {
EXPECT_TRUE(IsOSSnowLeopardOrEarlier());
EXPECT_FALSE(IsOSSnowLeopardOrLater());
EXPECT_FALSE(IsOSLion());
+ EXPECT_TRUE(IsOSLionOrEarlier());
EXPECT_FALSE(IsOSLionOrLater());
+ EXPECT_FALSE(IsOSMountainLion());
+ EXPECT_FALSE(IsOSMountainLionOrLater());
+ EXPECT_FALSE(
+ IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
EXPECT_FALSE(IsOSLaterThanLion());
} else if (minor == 6) {
EXPECT_FALSE(IsOSLeopard());
@@ -167,7 +172,12 @@ TEST_F(MacUtilTest, IsOSEllipsis) {
EXPECT_TRUE(IsOSSnowLeopardOrEarlier());
EXPECT_TRUE(IsOSSnowLeopardOrLater());
EXPECT_FALSE(IsOSLion());
+ EXPECT_TRUE(IsOSLionOrEarlier());
EXPECT_FALSE(IsOSLionOrLater());
+ EXPECT_FALSE(IsOSMountainLion());
+ EXPECT_FALSE(IsOSMountainLionOrLater());
+ EXPECT_FALSE(
+ IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
EXPECT_FALSE(IsOSLaterThanLion());
} else if (minor == 7) {
EXPECT_FALSE(IsOSLeopard());
@@ -176,10 +186,28 @@ TEST_F(MacUtilTest, IsOSEllipsis) {
EXPECT_FALSE(IsOSSnowLeopardOrEarlier());
EXPECT_TRUE(IsOSSnowLeopardOrLater());
EXPECT_TRUE(IsOSLion());
+ EXPECT_TRUE(IsOSLionOrEarlier());
EXPECT_TRUE(IsOSLionOrLater());
- EXPECT_FALSE(IsOSLaterThanLion());
+ EXPECT_FALSE(IsOSMountainLion());
+ EXPECT_FALSE(IsOSMountainLionOrLater());
+ EXPECT_FALSE(
+ IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
+ } else if (minor == 8) {
+ EXPECT_FALSE(IsOSLeopard());
+ EXPECT_FALSE(IsOSLeopardOrEarlier());
+ EXPECT_FALSE(IsOSSnowLeopard());
+ EXPECT_FALSE(IsOSSnowLeopardOrEarlier());
+ EXPECT_TRUE(IsOSSnowLeopardOrLater());
+ EXPECT_FALSE(IsOSLion());
+ EXPECT_FALSE(IsOSLionOrEarlier());
+ EXPECT_TRUE(IsOSLionOrLater());
+ EXPECT_TRUE(IsOSMountainLion());
+ EXPECT_TRUE(IsOSMountainLionOrLater());
+ EXPECT_FALSE(
+ IsOSDangerouslyLaterThanMountainLionForUseByCFAllocatorReplacement());
+ EXPECT_TRUE(IsOSLaterThanLion());
} else {
- // Not five, six, or seven. Ah, ah, ah.
+ // Not five, six, seven, or eight. Ah, ah, ah.
EXPECT_TRUE(false);
}
} else {
« 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