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

Side by Side Diff: chrome/browser/metrics/metrics_log_unittest.cc

Issue 7537033: Move more files from chrome/test to chrome/test/base, part #5 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 4 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/stringprintf.h" 7 #include "base/stringprintf.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "chrome/browser/metrics/metrics_log.h" 10 #include "chrome/browser/metrics/metrics_log.h"
11 #include "chrome/browser/prefs/browser_prefs.h" 11 #include "chrome/browser/prefs/browser_prefs.h"
12 #include "chrome/browser/prefs/pref_service.h" 12 #include "chrome/browser/prefs/pref_service.h"
13 #include "chrome/common/pref_names.h" 13 #include "chrome/common/pref_names.h"
14 #include "chrome/test/testing_pref_service.h" 14 #include "chrome/test/base/testing_pref_service.h"
15 #include "googleurl/src/gurl.h" 15 #include "googleurl/src/gurl.h"
16 #include "testing/gtest/include/gtest/gtest.h" 16 #include "testing/gtest/include/gtest/gtest.h"
17 17
18 using base::TimeDelta; 18 using base::TimeDelta;
19 19
20 namespace { 20 namespace {
21 class MetricsLogTest : public testing::Test { 21 class MetricsLogTest : public testing::Test {
22 }; 22 };
23 }; 23 };
24 24
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 // We're only checking the first 8 bytes, because that's what 263 // We're only checking the first 8 bytes, because that's what
264 // the metrics server uses. 264 // the metrics server uses.
265 std::string hash_hex = "0x"; 265 std::string hash_hex = "0x";
266 for (size_t j = 0; j < 8; j++) { 266 for (size_t j = 0; j < 8; j++) {
267 base::StringAppendF(&hash_hex, "%02x", 267 base::StringAppendF(&hash_hex, "%02x",
268 static_cast<uint8>(hash_string.data()[j])); 268 static_cast<uint8>(hash_string.data()[j]));
269 } 269 }
270 EXPECT_EQ(cases[i].output, hash_hex); 270 EXPECT_EQ(cases[i].output, hash_hex);
271 } 271 }
272 }; 272 };
OLDNEW
« no previous file with comments | « chrome/browser/google/google_url_tracker_unittest.cc ('k') | chrome/browser/net/connection_tester_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698