| Index: chrome/browser/ui/app_list/arc/arc_package_sync_data_type_controller.cc
|
| diff --git a/chrome/browser/ui/app_list/arc/arc_package_sync_data_type_controller.cc b/chrome/browser/ui/app_list/arc/arc_package_sync_data_type_controller.cc
|
| index 293b5d6947c0ca2a2460d02ada3754f3128a11a3..864c884b6477073170e4b5002b745a94305e09d3 100644
|
| --- a/chrome/browser/ui/app_list/arc/arc_package_sync_data_type_controller.cc
|
| +++ b/chrome/browser/ui/app_list/arc/arc_package_sync_data_type_controller.cc
|
| @@ -7,6 +7,7 @@
|
| #include "base/threading/thread_task_runner_handle.h"
|
| #include "chrome/browser/chromeos/arc/arc_util.h"
|
| #include "chrome/browser/profiles/profile.h"
|
| +#include "chrome/browser/ui/app_list/arc/arc_app_list_prefs_factory.h"
|
| #include "chrome/common/pref_names.h"
|
| #include "components/prefs/pref_service.h"
|
| #include "components/sync/base/pref_names.h"
|
| @@ -14,18 +15,6 @@
|
| #include "components/sync/driver/sync_client.h"
|
| #include "components/sync/driver/sync_service.h"
|
|
|
| -// ArcPackage sync service is controlled by apps checkbox in sync settings. ARC
|
| -// apps and regular Chrome apps have same user control.
|
| -namespace {
|
| -
|
| -// Indicates whether ARC is enabled on this machine.
|
| -bool IsArcEnabled(Profile* profile) {
|
| - return arc::IsArcAllowedForProfile(profile) &&
|
| - profile->GetPrefs()->GetBoolean(prefs::kArcEnabled);
|
| -}
|
| -
|
| -} // namespace
|
| -
|
| ArcPackageSyncDataTypeController::ArcPackageSyncDataTypeController(
|
| syncer::ModelType type,
|
| const base::Closure& dump_stack,
|
| @@ -49,7 +38,9 @@ ArcPackageSyncDataTypeController::~ArcPackageSyncDataTypeController() {
|
|
|
| bool ArcPackageSyncDataTypeController::ReadyForStart() const {
|
| DCHECK(CalledOnValidThread());
|
| - return IsArcEnabled(profile_) && ShouldSyncArc();
|
| + // In sync integration test, always consider the DTC as ready for start.
|
| + return ArcAppListPrefsFactory::IsFactorySetForSyncTest() ||
|
| + (arc::IsArcPlayStoreEnabledForProfile(profile_) && ShouldSyncArc());
|
| }
|
|
|
| bool ArcPackageSyncDataTypeController::StartModels() {
|
|
|