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

Unified Diff: chrome/test/live_sync/sync_errors_test.cc

Issue 7477004: Simulate transient error and verify exponential backoff. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Upload before commit. Created 9 years, 4 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 | « chrome/test/live_sync/live_sync_test.cc ('k') | net/tools/testserver/chromiumsync.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/live_sync/sync_errors_test.cc
diff --git a/chrome/test/live_sync/sync_errors_test.cc b/chrome/test/live_sync/sync_errors_test.cc
index 5d620a174010072ec39b24c66407bf32a21a1fbb..b0c7a168922118ab8c05f4cf9f3fdf08747d97c7 100644
--- a/chrome/test/live_sync/sync_errors_test.cc
+++ b/chrome/test/live_sync/sync_errors_test.cc
@@ -31,3 +31,18 @@ IN_PROC_BROWSER_TEST_F(SyncErrorTest, BirthdayErrorTest) {
SetTitle(0, node2, L"new_title2");
ASSERT_TRUE(GetClient(0)->AwaitSyncDisabled("Birthday error."));
}
+
+IN_PROC_BROWSER_TEST_F(SyncErrorTest, TransientErrorTest) {
+ ASSERT_TRUE(SetupSync()) << "SetupSync() failed.";
+
+ const BookmarkNode* node1 = AddFolder(0, 0, L"title1");
+ SetTitle(0, node1, L"new_title1");
+ ASSERT_TRUE(GetClient(0)->AwaitSyncCycleCompletion("Offline state change."));
+ TriggerTransientError();
+
+ // Now make one more change so we will do another sync.
+ const BookmarkNode* node2 = AddFolder(0, 0, L"title2");
+ SetTitle(0, node2, L"new_title2");
+ ASSERT_TRUE(
+ GetClient(0)->AwaitExponentialBackoffVerification());
+}
« no previous file with comments | « chrome/test/live_sync/live_sync_test.cc ('k') | net/tools/testserver/chromiumsync.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698