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

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

Issue 2694503002: [USS] Fix USS in sync_integration_tests in chromeos (Closed)
Patch Set: modified comments Created 3 years, 10 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
« no previous file with comments | « no previous file | chrome/browser/sync/test/integration/two_client_uss_sync_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
diff --git a/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc b/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
index 08ec1b58b4e52f573fe012366fe260853bc193ec..69c51bc0f108aa593ab06e87307ff52c5bd97e41 100644
--- a/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
+++ b/chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc
@@ -20,6 +20,10 @@
#include "components/sync/test/fake_server/fake_server_verifier.h"
#include "components/sync/test/fake_server/sessions_hierarchy.h"
+#if defined(OS_CHROMEOS)
+#include "chromeos/chromeos_switches.h"
+#endif
+
using base::HistogramBase;
using base::HistogramSamples;
using base::HistogramTester;
@@ -66,6 +70,15 @@ class SingleClientSessionsSyncTest : public SyncTest {
if (!cl->HasSwitch(switches::kSyncShortInitialRetryOverride))
cl->AppendSwitch(switches::kSyncShortInitialRetryOverride);
+
+#if defined(OS_CHROMEOS)
+ // kIgnoreUserProfileMappingForTests will let UserManager always return
+ // active user. If this switch is not set, sync test's profile will not
+ // match UserManager's active user, then UserManager won't return active
+ // user to our tests.
+ if (!cl->HasSwitch(chromeos::switches::kIgnoreUserProfileMappingForTests))
+ cl->AppendSwitch(chromeos::switches::kIgnoreUserProfileMappingForTests);
+#endif
}
private:
« no previous file with comments | « no previous file | chrome/browser/sync/test/integration/two_client_uss_sync_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698