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

Side by Side Diff: chrome/test/perf/tab_switching_test.cc

Issue 13145003: Rewrite std::string("") to std::string(), Linux edition. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Ugh Created 7 years, 8 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
« no previous file with comments | « chrome/test/perf/startup_test.cc ('k') | chrome/test/perf/url_fetch_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/command_line.h" 5 #include "base/command_line.h"
6 #include "base/environment.h" 6 #include "base/environment.h"
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 UITest::SetUp(); 62 UITest::SetUp();
63 } 63 }
64 64
65 static const int kNumCycles = 5; 65 static const int kNumCycles = 5;
66 66
67 void PrintTimings(const char* label, TimeDelta timings[kNumCycles], 67 void PrintTimings(const char* label, TimeDelta timings[kNumCycles],
68 bool important) { 68 bool important) {
69 std::string times; 69 std::string times;
70 for (int i = 0; i < kNumCycles; ++i) 70 for (int i = 0; i < kNumCycles; ++i)
71 base::StringAppendF(&times, "%.2f,", timings[i].InMillisecondsF()); 71 base::StringAppendF(&times, "%.2f,", timings[i].InMillisecondsF());
72 perf_test::PrintResultList("times", "", label, times, "ms", important); 72 perf_test::PrintResultList(
73 "times", std::string(), label, times, "ms", important);
73 } 74 }
74 75
75 void RunTabSwitchingUITest(const char* label, bool important) { 76 void RunTabSwitchingUITest(const char* label, bool important) {
76 // Shut down from window UITest sets up automatically. 77 // Shut down from window UITest sets up automatically.
77 UITest::TearDown(); 78 UITest::TearDown();
78 79
79 TimeDelta timings[kNumCycles]; 80 TimeDelta timings[kNumCycles];
80 for (int i = 0; i < kNumCycles; ++i) { 81 for (int i = 0; i < kNumCycles; ++i) {
81 // Prepare for this test run. 82 // Prepare for this test run.
82 SetUp(); 83 SetUp();
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 RunTabSwitchingUITest("t", true); 194 RunTabSwitchingUITest("t", true);
194 } 195 }
195 196
196 // Started failing with a webkit roll in r49936. See http://crbug.com/46751 197 // Started failing with a webkit roll in r49936. See http://crbug.com/46751
197 TEST_F(TabSwitchingUITest, DISABLED_TabSwitchRef) { 198 TEST_F(TabSwitchingUITest, DISABLED_TabSwitchRef) {
198 UseReferenceBuild(); 199 UseReferenceBuild();
199 RunTabSwitchingUITest("t_ref", true); 200 RunTabSwitchingUITest("t_ref", true);
200 } 201 }
201 202
202 } // namespace 203 } // namespace
OLDNEW
« no previous file with comments | « chrome/test/perf/startup_test.cc ('k') | chrome/test/perf/url_fetch_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698