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

Unified Diff: chrome/test/testing_profile.cc

Issue 7063030: PrintPreview: Print Preview is not staying associated with initiator renderer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 9 years, 7 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
Index: chrome/test/testing_profile.cc
diff --git a/chrome/test/testing_profile.cc b/chrome/test/testing_profile.cc
index 2c1d98c562cb6b49435f112af24f45e56675ad1b..c3f134d61fa93a02d2f319154d46fd7aa3e87b72 100644
--- a/chrome/test/testing_profile.cc
+++ b/chrome/test/testing_profile.cc
@@ -33,6 +33,8 @@
#include "chrome/browser/prefs/browser_prefs.h"
#include "chrome/browser/prefs/testing_pref_store.h"
#include "chrome/browser/prerender/prerender_manager.h"
+#include "chrome/browser/printing/print_preview_data_service.h"
+#include "chrome/browser/printing/print_preview_data_service_factory.h"
#include "chrome/browser/profiles/profile_dependency_manager.h"
#include "chrome/browser/search_engines/template_url_fetcher.h"
#include "chrome/browser/search_engines/template_url_model.h"
@@ -118,6 +120,10 @@ ProfileKeyedService* CreateTestDesktopNotificationService(Profile* profile) {
return new DesktopNotificationService(profile, NULL);
}
+ProfileKeyedService* CreateTestPrintPreviewDataService(Profile* profile) {
+ return new PrintPreviewDataService();
+}
+
} // namespace
TestingProfile::TestingProfile()
@@ -159,6 +165,8 @@ TestingProfile::TestingProfile()
this, NULL);
SessionServiceFactory::GetInstance()->ForceAssociationBetween(this, NULL);
TabRestoreServiceFactory::GetInstance()->ForceAssociationBetween(this, NULL);
+ PrintPreviewDataServiceFactory::GetInstance()->set_test_factory(
Lei Zhang 2011/05/27 17:26:53 nit: keep it in alphabetical order?
kmadhusu 2011/05/27 23:44:42 Done.
+ &CreateTestPrintPreviewDataService);
}
TestingProfile::~TestingProfile() {
« chrome/browser/ui/webui/print_preview_ui_data_source_unittest.cc ('K') | « chrome/chrome_tests.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698