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

Unified Diff: chrome/test/startup/feature_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 | « no previous file | chrome/test/startup/startup_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/startup/feature_startup_test.cc
===================================================================
--- chrome/test/startup/feature_startup_test.cc (revision 22523)
+++ chrome/test/startup/feature_startup_test.cc (working copy)
@@ -19,17 +19,6 @@
namespace {
-// Returns the directory name where the "typical" user data is that we use for
-// testing.
-FilePath ComputeTypicalUserDataSource() {
- FilePath source_history_file;
- EXPECT_TRUE(PathService::Get(chrome::DIR_TEST_DATA,
- &source_history_file));
- source_history_file = source_history_file.AppendASCII("profiles")
- .AppendASCII("typical_history");
- return source_history_file;
-}
-
class NewTabUIStartupTest : public UITest {
public:
NewTabUIStartupTest() {
@@ -52,9 +41,11 @@
// Run the test, by bringing up a browser and timing the new tab startup.
// |want_warm| is true if we should output warm-disk timings, false if
// we should report cold timings.
- void RunStartupTest(const char* label, bool want_warm, bool important) {
+ void RunStartupTest(const char* label, bool want_warm, bool important,
+ int profile_type) {
// Install the location of the test profile file.
- set_template_user_data(ComputeTypicalUserDataSource().ToWStringHack());
+ set_template_user_data(UITest::ComputeTypicalUserDataSource(
+ profile_type).ToWStringHack());
// Disable the first run notification because it has an animation which
// masks any real performance regressions.
@@ -106,11 +97,19 @@
// TODO(pamg): run these tests with a reference build?
TEST_F(NewTabUIStartupTest, PerfCold) {
- RunStartupTest("tab_cold", false /* cold */, true /* important */);
+ RunStartupTest("tab_cold", false /* cold */, true /* important */,
+ UITest::DEFAULT_THEME);
}
TEST_F(NewTabUIStartupTest, DISABLED_PerfWarm) {
- RunStartupTest("tab_warm", true /* warm */, false /* not important */);
+ RunStartupTest("tab_warm", true /* warm */, false /* not important */,
+ UITest::DEFAULT_THEME);
}
+TEST_F(NewTabUIStartupTest, ComplexTheme) {
+ RunStartupTest("tab_complex_theme_cold", false /* cold */,
+ false /* not important */,
+ UITest::COMPLEX_THEME);
+}
+
} // namespace
« no previous file with comments | « no previous file | chrome/test/startup/startup_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698