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

Side by Side Diff: chrome/test/startup/feature_startup_test.cc

Issue 7562019: ntp: remove dead first run code (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: compile fix 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
« no previous file with comments | « chrome/common/chrome_switches.cc ('k') | no next file » | 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) 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 "base/file_util.h" 5 #include "base/file_util.h"
6 #include "base/path_service.h" 6 #include "base/path_service.h"
7 #include "base/perftimer.h" 7 #include "base/perftimer.h"
8 #include "base/stringprintf.h" 8 #include "base/stringprintf.h"
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "chrome/app/chrome_command_ids.h" 10 #include "chrome/app/chrome_command_ids.h"
(...skipping 28 matching lines...) Expand all
39 base::StringAppendF(&times, "%.2f,", timings[i].InMillisecondsF()); 39 base::StringAppendF(&times, "%.2f,", timings[i].InMillisecondsF());
40 PrintResultList("new_tab", "", label, times, "ms", important); 40 PrintResultList("new_tab", "", label, times, "ms", important);
41 } 41 }
42 42
43 void InitProfile(UITestBase::ProfileType profile_type) { 43 void InitProfile(UITestBase::ProfileType profile_type) {
44 profile_type_ = profile_type; 44 profile_type_ = profile_type;
45 45
46 // Install the location of the test profile file. 46 // Install the location of the test profile file.
47 set_template_user_data(UITest::ComputeTypicalUserDataSource( 47 set_template_user_data(UITest::ComputeTypicalUserDataSource(
48 profile_type)); 48 profile_type));
49
50 // Disable the first run notification because it has an animation which
51 // masks any real performance regressions.
52 launch_arguments_.AppendSwitch(switches::kDisableNewTabFirstRun);
53 } 49 }
54 50
55 // Run the test, by bringing up a browser and timing the new tab startup. 51 // Run the test, by bringing up a browser and timing the new tab startup.
56 // |want_warm| is true if we should output warm-disk timings, false if 52 // |want_warm| is true if we should output warm-disk timings, false if
57 // we should report cold timings. 53 // we should report cold timings.
58 void RunStartupTest(const char* label, bool want_warm, bool important, 54 void RunStartupTest(const char* label, bool want_warm, bool important,
59 UITestBase::ProfileType profile_type) { 55 UITestBase::ProfileType profile_type) {
60 InitProfile(profile_type); 56 InitProfile(profile_type);
61 57
62 TimeDelta timings[kNumCycles]; 58 TimeDelta timings[kNumCycles];
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 } 209 }
214 210
215 TEST_F(NewTabUIStartupTest, NativeFrameGtkThemeCold) { 211 TEST_F(NewTabUIStartupTest, NativeFrameGtkThemeCold) {
216 RunStartupTest("tab_custom_frame_gtk_theme_cold", false /* cold */, 212 RunStartupTest("tab_custom_frame_gtk_theme_cold", false /* cold */,
217 false /* not important */, 213 false /* not important */,
218 UITestBase::CUSTOM_FRAME_NATIVE_THEME); 214 UITestBase::CUSTOM_FRAME_NATIVE_THEME);
219 } 215 }
220 #endif 216 #endif
221 217
222 } // namespace 218 } // namespace
OLDNEW
« no previous file with comments | « chrome/common/chrome_switches.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698