| Index: chrome/browser/sync/test/integration/apps_helper.cc
|
| diff --git a/chrome/browser/sync/test/integration/apps_helper.cc b/chrome/browser/sync/test/integration/apps_helper.cc
|
| index 435694010dc5fd827d937c75dda078e6ce643a5c..2b76b4d893f1a08c1eb0db477edf4cceb5feff38 100644
|
| --- a/chrome/browser/sync/test/integration/apps_helper.cc
|
| +++ b/chrome/browser/sync/test/integration/apps_helper.cc
|
| @@ -35,16 +35,16 @@
|
|
|
| namespace apps_helper {
|
|
|
| -bool HasSameApps(Profile* profile1, Profile* profile2) {
|
| - return SyncAppHelper::GetInstance()->AppStatesMatch(profile1, profile2);
|
| -}
|
| -
|
| -bool AllProfilesHaveSameApps() {
|
| - const auto& profiles = test()->GetAllProfiles();
|
| - for (auto* profile : profiles) {
|
| - if (profile != profiles.front() &&
|
| - !HasSameApps(profiles.front(), profile)) {
|
| - DVLOG(1) << "Profiles apps do not match.";
|
| +bool HasSameAppsAsVerifier(int index) {
|
| + return SyncAppHelper::GetInstance()->AppStatesMatch(
|
| + test()->GetProfile(index), test()->verifier());
|
| +}
|
| +
|
| +bool AllProfilesHaveSameAppsAsVerifier() {
|
| + for (int i = 0; i < test()->num_clients(); ++i) {
|
| + if (!HasSameAppsAsVerifier(i)) {
|
| + DVLOG(1) << "Profile " << i << " doesn't have the same apps as the"
|
| + " verifier profile.";
|
| return false;
|
| }
|
| }
|
| @@ -66,11 +66,9 @@
|
| }
|
|
|
| std::string InstallAppForAllProfiles(int index) {
|
| - std::string extension_id;
|
| - for (auto* profile : test()->GetAllProfiles()) {
|
| - extension_id = InstallApp(profile, index);
|
| - }
|
| - return extension_id;
|
| + for (int i = 0; i < test()->num_clients(); ++i)
|
| + InstallApp(test()->GetProfile(i), index);
|
| + return InstallApp(test()->verifier(), index);
|
| }
|
|
|
| void UninstallApp(Profile* profile, int index) {
|
| @@ -88,11 +86,6 @@
|
| profile, CreateFakeAppName(index));
|
| }
|
|
|
| -bool IsAppEnabled(Profile* profile, int index) {
|
| - return SyncExtensionHelper::GetInstance()->IsExtensionEnabled(
|
| - profile, CreateFakeAppName(index));
|
| -}
|
| -
|
| void IncognitoEnableApp(Profile* profile, int index) {
|
| return SyncExtensionHelper::GetInstance()->IncognitoEnableExtension(
|
| profile, CreateFakeAppName(index));
|
| @@ -100,11 +93,6 @@
|
|
|
| void IncognitoDisableApp(Profile* profile, int index) {
|
| return SyncExtensionHelper::GetInstance()->IncognitoDisableExtension(
|
| - profile, CreateFakeAppName(index));
|
| -}
|
| -
|
| -bool IsIncognitoEnabled(Profile* profile, int index) {
|
| - return SyncExtensionHelper::GetInstance()->IsIncognitoEnabled(
|
| profile, CreateFakeAppName(index));
|
| }
|
|
|
|
|