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

Unified Diff: google_apis/drive/request_sender_unittest.cc

Issue 1218773003: Implement a DRIVE_REQUEST_TOO_LARGE backoff. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 5 years, 6 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
Index: google_apis/drive/request_sender_unittest.cc
diff --git a/google_apis/drive/request_sender_unittest.cc b/google_apis/drive/request_sender_unittest.cc
index 63e8a8f42f79ef92677194487689d6c79c835598..fb4a1569be804bcc26e5c6a37a1478e91c1306cc 100644
--- a/google_apis/drive/request_sender_unittest.cc
+++ b/google_apis/drive/request_sender_unittest.cc
@@ -139,7 +139,8 @@ TEST_F(RequestSenderTest, StartAndFinishRequest) {
&finish_reason);
base::WeakPtr<AuthenticatedRequestInterface> weak_ptr = request->GetWeakPtr();
- base::Closure cancel_closure = request_sender_.StartRequestWithRetry(request);
+ base::Closure cancel_closure =
+ request_sender_.StartRequestWithAuthRetry(request);
EXPECT_TRUE(!cancel_closure.is_null());
// Start is called with the specified access token. Let it succeed.
@@ -162,7 +163,8 @@ TEST_F(RequestSenderTest, StartAndCancelRequest) {
&finish_reason);
base::WeakPtr<AuthenticatedRequestInterface> weak_ptr = request->GetWeakPtr();
- base::Closure cancel_closure = request_sender_.StartRequestWithRetry(request);
+ base::Closure cancel_closure =
+ request_sender_.StartRequestWithAuthRetry(request);
EXPECT_TRUE(!cancel_closure.is_null());
EXPECT_TRUE(start_called);
@@ -182,7 +184,8 @@ TEST_F(RequestSenderTest, NoRefreshToken) {
&finish_reason);
base::WeakPtr<AuthenticatedRequestInterface> weak_ptr = request->GetWeakPtr();
- base::Closure cancel_closure = request_sender_.StartRequestWithRetry(request);
+ base::Closure cancel_closure =
+ request_sender_.StartRequestWithAuthRetry(request);
EXPECT_TRUE(!cancel_closure.is_null());
// The request is not started at all because no access token is obtained.
@@ -201,7 +204,8 @@ TEST_F(RequestSenderTest, ValidRefreshTokenAndNoAccessToken) {
&finish_reason);
base::WeakPtr<AuthenticatedRequestInterface> weak_ptr = request->GetWeakPtr();
- base::Closure cancel_closure = request_sender_.StartRequestWithRetry(request);
+ base::Closure cancel_closure =
+ request_sender_.StartRequestWithAuthRetry(request);
EXPECT_TRUE(!cancel_closure.is_null());
// Access token should indicate that this is the first retry.
@@ -221,7 +225,8 @@ TEST_F(RequestSenderTest, AccessTokenRejectedSeveralTimes) {
&finish_reason);
base::WeakPtr<AuthenticatedRequestInterface> weak_ptr = request->GetWeakPtr();
- base::Closure cancel_closure = request_sender_.StartRequestWithRetry(request);
+ base::Closure cancel_closure =
+ request_sender_.StartRequestWithAuthRetry(request);
EXPECT_TRUE(!cancel_closure.is_null());
EXPECT_TRUE(start_called);

Powered by Google App Engine
This is Rietveld 408576698