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

Unified Diff: chrome/test/startup/startup_test.cc

Issue 165168: Test startup of new tab page with a complex theme.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/startup/feature_startup_test.cc ('k') | chrome/test/ui/ui_test.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/startup/startup_test.cc
===================================================================
--- chrome/test/startup/startup_test.cc (revision 22523)
+++ chrome/test/startup/startup_test.cc (working copy)
@@ -28,7 +28,7 @@
void TearDown() {}
void RunStartupTest(const char* graph, const char* trace,
- bool test_cold, bool important) {
+ bool test_cold, bool important, int profile_type) {
const int kNumCyclesMax = 20;
int numCycles = kNumCyclesMax;
// It's ok for unit test code to use getenv(), isn't it?
@@ -65,6 +65,12 @@
#endif
}
+ // Sets the profile data for the run. For now, this is only used for
+ // the complex theme test.
+ if (profile_type == UITest::COMPLEX_THEME)
+ set_template_user_data(UITest::ComputeTypicalUserDataSource(
+ profile_type).ToWStringHack());
+
UITest::SetUp();
TimeTicks end_time = TimeTicks::Now();
timings[i] = end_time - browser_launch_time_;
@@ -125,32 +131,39 @@
};
TEST_F(StartupTest, Perf) {
- RunStartupTest("warm", "t", false /* not cold */, true /* important */);
+ RunStartupTest("warm", "t", false /* not cold */, true /* important */,
+ UITest::DEFAULT_THEME);
}
// TODO(port): We need a mac reference build checked in for this.
TEST_F(StartupReferenceTest, Perf) {
RunStartupTest("warm", "t_ref", false /* not cold */,
- true /* important */);
+ true /* important */, UITest::DEFAULT_THEME);
}
// TODO(mpcomplete): Should we have reference timings for all these?
TEST_F(StartupTest, PerfCold) {
- RunStartupTest("cold", "t", true /* cold */, false /* not important */);
+ RunStartupTest("cold", "t", true /* cold */, false /* not important */,
+ UITest::DEFAULT_THEME);
}
#if defined(OS_WIN)
// TODO(port): Enable gears tests on linux/mac once gears is working.
TEST_F(StartupFileTest, PerfGears) {
RunStartupTest("warm", "gears", false /* not cold */,
- false /* not important */);
+ false /* not important */, UITest::DEFAULT_THEME);
}
TEST_F(StartupFileTest, PerfColdGears) {
RunStartupTest("cold", "gears", true /* cold */,
- false /* not important */);
+ false /* not important */, UITest::DEFAULT_THEME);
}
#endif
+TEST_F(StartupTest, PerfColdComplexTheme) {
+ RunStartupTest("warm", "t-theme", false /* warm */,
+ false /* not important */, UITest::COMPLEX_THEME);
+}
+
} // namespace
« no previous file with comments | « chrome/test/startup/feature_startup_test.cc ('k') | chrome/test/ui/ui_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698