summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync
diff options
context:
space:
mode:
authorrsimha@chromium.org <rsimha@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-20 00:00:27 +0000
committerrsimha@chromium.org <rsimha@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-20 00:00:27 +0000
commitee711ac84cee870f9ebdd6a2f93e101784c9a89b (patch)
treed452da2b9f3cc1722d81a43792aab8a02853bfb2 /chrome/browser/sync
parent266a59956430c8caf974c7d5a18912d5e4b866e9 (diff)
downloadchromium_src-ee711ac84cee870f9ebdd6a2f93e101784c9a89b.zip
chromium_src-ee711ac84cee870f9ebdd6a2f93e101784c9a89b.tar.gz
chromium_src-ee711ac84cee870f9ebdd6a2f93e101784c9a89b.tar.bz2
Logging tweak for sync integration tests
Required to debug some buildbot failures that do not repro locally. BUG=63823 TEST=sync_integration_tests Review URL: http://codereview.chromium.org/5105007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@66843 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync')
-rw-r--r--chrome/browser/sync/profile_sync_service_harness.cc28
1 files changed, 16 insertions, 12 deletions
diff --git a/chrome/browser/sync/profile_sync_service_harness.cc b/chrome/browser/sync/profile_sync_service_harness.cc
index 4ac3915..d981fd8 100644
--- a/chrome/browser/sync/profile_sync_service_harness.cc
+++ b/chrome/browser/sync/profile_sync_service_harness.cc
@@ -238,6 +238,18 @@ bool ProfileSyncServiceHarness::RunStateChangeMachine() {
}
break;
}
+ case WAITING_FOR_PASSPHRASE_REQUIRED: {
+ LogClientInfo("WAITING_FOR_PASSPHRASE_REQUIRED");
+ if (service_->observed_passphrase_required())
+ SignalStateCompleteWithNextState(WAITING_FOR_PASSPHRASE_ACCEPTED);
+ break;
+ }
+ case WAITING_FOR_PASSPHRASE_ACCEPTED: {
+ LogClientInfo("WAITING_FOR_PASSPHRASE_ACCEPTED");
+ if (passphrase_acceptance_counter_ >= 0)
+ SignalStateCompleteWithNextState(WAITING_FOR_INITIAL_SYNC);
+ break;
+ }
case WAITING_FOR_INITIAL_SYNC: {
LogClientInfo("WAITING_FOR_INITIAL_SYNC");
if (IsSynced()) {
@@ -285,18 +297,6 @@ bool ProfileSyncServiceHarness::RunStateChangeMachine() {
LogClientInfo("FULLY_SYNCED");
break;
}
- case WAITING_FOR_PASSPHRASE_REQUIRED: {
- LogClientInfo("WAITING_FOR_PASSPHRASE_REQUIRED");
- if (service_->observed_passphrase_required())
- SignalStateCompleteWithNextState(WAITING_FOR_PASSPHRASE_ACCEPTED);
- break;
- }
- case WAITING_FOR_PASSPHRASE_ACCEPTED: {
- LogClientInfo("WAITING_FOR_PASSPHRASE_ACCEPTED");
- if (passphrase_acceptance_counter_ >= 0)
- SignalStateCompleteWithNextState(WAITING_FOR_INITIAL_SYNC);
- break;
- }
case SYNC_DISABLED: {
// Syncing is disabled for the client. There is nothing to do.
LogClientInfo("SYNC_DISABLED");
@@ -460,6 +460,7 @@ ProfileSyncService::Status ProfileSyncServiceHarness::GetStatus() {
}
bool ProfileSyncServiceHarness::IsSynced() {
+ LogClientInfo("IsSynced");
if (service() == NULL)
return false;
const SyncSessionSnapshot* snap = GetLastSessionSnapshot();
@@ -577,8 +578,11 @@ void ProfileSyncServiceHarness::LogClientInfo(std::string message) {
<< ": max_local_timestamp: " << snap->max_local_timestamp
<< ", has_more_to_sync: " << snap->has_more_to_sync
<< ", unsynced_count: " << snap->unsynced_count
+ << ", num_conflicting_updates: " << snap->num_conflicting_updates
<< ", has_unsynced_items: "
<< service()->backend()->HasUnsyncedItems()
+ << ", observed_passphrase_required: "
+ << service()->observed_passphrase_required()
<< ", notifications_enabled: "
<< GetStatus().notifications_enabled
<< ", service_is_pushing_changes: " << ServiceIsPushingChanges();