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

Unified Diff: chrome/browser/sync/test/integration/single_client_apps_sync_test.cc

Issue 11117011: Keep browser process alive while there are platform apps with background pages running. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: And another test Created 8 years 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/browser/sync/test/integration/single_client_apps_sync_test.cc
diff --git a/chrome/browser/sync/test/integration/single_client_apps_sync_test.cc b/chrome/browser/sync/test/integration/single_client_apps_sync_test.cc
index 320b4a2a79d1f3f8bb2cc023ff9d274f4288c687..d3139ca065013fd1b184838b940b9de630a345d4 100644
--- a/chrome/browser/sync/test/integration/single_client_apps_sync_test.cc
+++ b/chrome/browser/sync/test/integration/single_client_apps_sync_test.cc
@@ -3,13 +3,16 @@
// found in the LICENSE file.
#include "base/basictypes.h"
+#include "base/command_line.h"
#include "chrome/browser/sync/profile_sync_service_harness.h"
#include "chrome/browser/sync/test/integration/apps_helper.h"
#include "chrome/browser/sync/test/integration/sync_test.h"
+#include "chrome/common/chrome_switches.h"
using apps_helper::AllProfilesHaveSameAppsAsVerifier;
using apps_helper::InstallApp;
using apps_helper::InstallPlatformApp;
+using apps_helper::WaitForPlatformAppsToUnload;
class SingleClientAppsSyncTest : public SyncTest {
public:
@@ -17,6 +20,14 @@ class SingleClientAppsSyncTest : public SyncTest {
virtual ~SingleClientAppsSyncTest() {}
+ protected:
+ virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE {
+ SyncTest::SetUpCommandLine(command_line);
+ // Make event pages get suspended quicker.
+ command_line->AppendSwitchASCII(switches::kEventPageIdleTime, "1");
+ command_line->AppendSwitchASCII(switches::kEventPageUnloadingTime, "1");
+ }
+
private:
DISALLOW_COPY_AND_ASSIGN(SingleClientAppsSyncTest);
};
@@ -53,6 +64,8 @@ IN_PROC_BROWSER_TEST_F(SingleClientAppsSyncTest, StartWithSomePlatformApps) {
ASSERT_TRUE(SetupSync());
ASSERT_TRUE(AllProfilesHaveSameAppsAsVerifier());
+
+ WaitForPlatformAppsToUnload();
}
IN_PROC_BROWSER_TEST_F(SingleClientAppsSyncTest, InstallSomeLegacyApps) {
@@ -83,6 +96,8 @@ IN_PROC_BROWSER_TEST_F(SingleClientAppsSyncTest, InstallSomePlatformApps) {
"Waiting for app changes."));
ASSERT_TRUE(AllProfilesHaveSameAppsAsVerifier());
+
+ WaitForPlatformAppsToUnload();
}
IN_PROC_BROWSER_TEST_F(SingleClientAppsSyncTest, InstallSomeApps) {
@@ -106,4 +121,6 @@ IN_PROC_BROWSER_TEST_F(SingleClientAppsSyncTest, InstallSomeApps) {
"Waiting for app changes."));
ASSERT_TRUE(AllProfilesHaveSameAppsAsVerifier());
+
+ WaitForPlatformAppsToUnload();
}
« no previous file with comments | « chrome/browser/sync/test/integration/apps_helper.cc ('k') | chrome/browser/sync/test/integration/two_client_apps_sync_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698