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

Side by Side Diff: components/visitedlink/test/visitedlink_perftest.cc

Issue 16950028: Move file_util::Delete to the base namespace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 5 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 <algorithm> 5 #include <algorithm>
6 #include <string> 6 #include <string>
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 master.AddURL(TestURL(prefix, i)); 59 master.AddURL(TestURL(prefix, i));
60 } 60 }
61 61
62 class VisitedLink : public testing::Test { 62 class VisitedLink : public testing::Test {
63 protected: 63 protected:
64 base::FilePath db_path_; 64 base::FilePath db_path_;
65 virtual void SetUp() { 65 virtual void SetUp() {
66 ASSERT_TRUE(file_util::CreateTemporaryFile(&db_path_)); 66 ASSERT_TRUE(file_util::CreateTemporaryFile(&db_path_));
67 } 67 }
68 virtual void TearDown() { 68 virtual void TearDown() {
69 file_util::Delete(db_path_, false); 69 base::Delete(db_path_, false);
70 } 70 }
71 }; 71 };
72 72
73 } // namespace 73 } // namespace
74 74
75 // This test tests adding many things to a database, and how long it takes 75 // This test tests adding many things to a database, and how long it takes
76 // to query the database with different numbers of things in it. The time 76 // to query the database with different numbers of things in it. The time
77 // is the total time to do all the operations, and as such, it is only 77 // is the total time to do all the operations, and as such, it is only
78 // useful for a regression test. If there is a regression, it might be 78 // useful for a regression test. If there is a regression, it might be
79 // useful to make another set of tests to test these things in isolation. 79 // useful to make another set of tests to test these things in isolation.
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 cold_sum += cold_load_times[i]; 190 cold_sum += cold_load_times[i];
191 hot_sum += hot_load_times[i]; 191 hot_sum += hot_load_times[i];
192 } 192 }
193 LogPerfResult("Visited_link_cold_load_time", 193 LogPerfResult("Visited_link_cold_load_time",
194 cold_sum / cold_load_times.size(), "ms"); 194 cold_sum / cold_load_times.size(), "ms");
195 LogPerfResult("Visited_link_hot_load_time", 195 LogPerfResult("Visited_link_hot_load_time",
196 hot_sum / hot_load_times.size(), "ms"); 196 hot_sum / hot_load_times.size(), "ms");
197 } 197 }
198 198
199 } // namespace visitedlink 199 } // namespace visitedlink
OLDNEW
« no previous file with comments | « cloud_print/virtual_driver/win/port_monitor/port_monitor_unittest.cc ('k') | content/browser/download/base_file.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698