| OLD | NEW |
| 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 #include "base/file_util.h" | 5 #include "base/file_util.h" |
| 6 #include "base/sys_info.h" | 6 #include "base/sys_info.h" |
| 7 #include "base/threading/platform_thread.h" | 7 #include "base/threading/platform_thread.h" |
| 8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
| 9 #include "testing/platform_test.h" | 9 #include "testing/platform_test.h" |
| 10 | 10 |
| 11 typedef PlatformTest SysInfoTest; | 11 typedef PlatformTest SysInfoTest; |
| 12 using base::FilePath; |
| 12 | 13 |
| 13 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) | 14 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_ANDROID) |
| 14 TEST_F(SysInfoTest, MaxSharedMemorySize) { | 15 TEST_F(SysInfoTest, MaxSharedMemorySize) { |
| 15 // We aren't actually testing that it's correct, just that it's sane. | 16 // We aren't actually testing that it's correct, just that it's sane. |
| 16 EXPECT_GT(base::SysInfo::MaxSharedMemorySize(), 0u); | 17 EXPECT_GT(base::SysInfo::MaxSharedMemorySize(), 0u); |
| 17 } | 18 } |
| 18 #endif | 19 #endif |
| 19 | 20 |
| 20 TEST_F(SysInfoTest, NumProcs) { | 21 TEST_F(SysInfoTest, NumProcs) { |
| 21 // We aren't actually testing that it's correct, just that it's sane. | 22 // We aren't actually testing that it's correct, just that it's sane. |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 base::SysInfo::ParseLsbRelease(lsb_release, | 102 base::SysInfo::ParseLsbRelease(lsb_release, |
| 102 &os_major_version, | 103 &os_major_version, |
| 103 &os_minor_version, | 104 &os_minor_version, |
| 104 &os_bugfix_version); | 105 &os_bugfix_version); |
| 105 EXPECT_EQ(-1, os_major_version); | 106 EXPECT_EQ(-1, os_major_version); |
| 106 EXPECT_EQ(-1, os_minor_version); | 107 EXPECT_EQ(-1, os_minor_version); |
| 107 EXPECT_EQ(-1, os_bugfix_version); | 108 EXPECT_EQ(-1, os_bugfix_version); |
| 108 } | 109 } |
| 109 | 110 |
| 110 #endif // OS_CHROMEOS | 111 #endif // OS_CHROMEOS |
| OLD | NEW |