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 <string> | 5 #include <string> |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/port.h" | 8 #include "base/port.h" |
9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/stringprintf.h" | 10 #include "base/stringprintf.h" |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 } | 90 } |
91 | 91 |
92 virtual float GetScreenDeviceScaleFactor() const OVERRIDE { | 92 virtual float GetScreenDeviceScaleFactor() const OVERRIDE { |
93 return kScreenScaleFactor; | 93 return kScreenScaleFactor; |
94 } | 94 } |
95 | 95 |
96 virtual int GetScreenCount() const OVERRIDE { | 96 virtual int GetScreenCount() const OVERRIDE { |
97 return kScreenCount; | 97 return kScreenCount; |
98 } | 98 } |
99 | 99 |
100 TestingPrefService prefs_; | 100 TestingPrefServiceSimple prefs_; |
101 | 101 |
102 DISALLOW_COPY_AND_ASSIGN(TestMetricsLog); | 102 DISALLOW_COPY_AND_ASSIGN(TestMetricsLog); |
103 }; | 103 }; |
104 | 104 |
105 } // namespace | 105 } // namespace |
106 | 106 |
107 class MetricsLogTest : public testing::Test { | 107 class MetricsLogTest : public testing::Test { |
108 protected: | 108 protected: |
109 void TestRecordEnvironment(bool proto_only) { | 109 void TestRecordEnvironment(bool proto_only) { |
110 TestMetricsLog log(kClientId, kSessionId); | 110 TestMetricsLog log(kClientId, kSessionId); |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
307 EXPECT_NE(std::string::npos, | 307 EXPECT_NE(std::string::npos, |
308 encoded.find(" childprocesscrashcount=\"10\"")); | 308 encoded.find(" childprocesscrashcount=\"10\"")); |
309 EXPECT_EQ(std::string::npos, | 309 EXPECT_EQ(std::string::npos, |
310 encoded.find(" otherusercrashcount=")); | 310 encoded.find(" otherusercrashcount=")); |
311 EXPECT_EQ(std::string::npos, | 311 EXPECT_EQ(std::string::npos, |
312 encoded.find(" kernelcrashcount=")); | 312 encoded.find(" kernelcrashcount=")); |
313 EXPECT_EQ(std::string::npos, | 313 EXPECT_EQ(std::string::npos, |
314 encoded.find(" systemuncleanshutdowns=")); | 314 encoded.find(" systemuncleanshutdowns=")); |
315 } | 315 } |
316 #endif // OS_CHROMEOS | 316 #endif // OS_CHROMEOS |
OLD | NEW |