| Index: chrome/browser/ui/app_list/app_list_syncable_service_factory.cc
|
| diff --git a/chrome/browser/ui/app_list/app_list_syncable_service_factory.cc b/chrome/browser/ui/app_list/app_list_syncable_service_factory.cc
|
| index 9d89d8b3688a90334ad6da86867c4f3f491a5d00..7d3509bdc889ea2bfdaa8590bf50c438e5071cfc 100644
|
| --- a/chrome/browser/ui/app_list/app_list_syncable_service_factory.cc
|
| +++ b/chrome/browser/ui/app_list/app_list_syncable_service_factory.cc
|
| @@ -25,6 +25,10 @@
|
|
|
| namespace app_list {
|
|
|
| +namespace {
|
| +bool use_in_testing = false;
|
| +}
|
| +
|
| // static
|
| AppListSyncableService* AppListSyncableServiceFactory::GetForProfile(
|
| Profile* profile) {
|
| @@ -51,6 +55,11 @@ std::unique_ptr<KeyedService> AppListSyncableServiceFactory::BuildInstanceFor(
|
| profile, extensions::ExtensionSystem::Get(profile)));
|
| }
|
|
|
| +// static
|
| +void AppListSyncableServiceFactory::SetUseInTesting() {
|
| + use_in_testing = true;
|
| +}
|
| +
|
| AppListSyncableServiceFactory::AppListSyncableServiceFactory()
|
| : BrowserContextKeyedServiceFactory(
|
| "AppListSyncableService",
|
| @@ -97,7 +106,7 @@ bool AppListSyncableServiceFactory::ServiceIsCreatedWithBrowserContext() const {
|
| }
|
|
|
| bool AppListSyncableServiceFactory::ServiceIsNULLWhileTesting() const {
|
| - return true;
|
| + return !use_in_testing;
|
| }
|
|
|
| } // namespace app_list
|
|
|