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

Unified Diff: chrome/browser/google_apis/gdata_wapi_requests_unittest.cc

Issue 16268017: GTTF: convert some tests in chrome to use EmbeddedTestServer patch nr 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 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
« no previous file with comments | « chrome/browser/google_apis/drive_api_requests_unittest.cc ('k') | chrome/browser/google_apis/test_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/google_apis/gdata_wapi_requests_unittest.cc
diff --git a/chrome/browser/google_apis/gdata_wapi_requests_unittest.cc b/chrome/browser/google_apis/gdata_wapi_requests_unittest.cc
index 442de142cde533e2afb40892f52327a5017c4fd3..13410bf7c0895f09218e5878f6b42b9770304c20 100644
--- a/chrome/browser/google_apis/gdata_wapi_requests_unittest.cc
+++ b/chrome/browser/google_apis/gdata_wapi_requests_unittest.cc
@@ -222,7 +222,7 @@ class GDataWapiRequestsTest : public testing::Test {
if (found != request.headers.end() &&
found->second != "*" &&
found->second != kTestETag) {
- http_response->set_code(net::test_server::PRECONDITION);
+ http_response->set_code(net::HTTP_PRECONDITION_FAILED);
return http_response.PassAs<net::test_server::HttpResponse>();
}
@@ -235,7 +235,7 @@ class GDataWapiRequestsTest : public testing::Test {
}
received_bytes_ = 0;
- http_response->set_code(net::test_server::SUCCESS);
+ http_response->set_code(net::HTTP_OK);
GURL upload_url;
// POST is used for a new file, and PUT is used for an existing file.
if (request.method == net::test_server::METHOD_POST) {
@@ -271,7 +271,7 @@ class GDataWapiRequestsTest : public testing::Test {
// response.code() is set to SUCCESS. Change it to CREATED if it's a new
// file.
if (absolute_url.path() == "/upload_new_file")
- response->set_code(net::test_server::CREATED);
+ response->set_code(net::HTTP_CREATED);
// Check if the Content-Range header is present. This must be present if
// the request body is not empty.
@@ -306,7 +306,7 @@ class GDataWapiRequestsTest : public testing::Test {
// Change the code to RESUME_INCOMPLETE if upload is not complete.
if (received_bytes_ < content_length_)
- response->set_code(net::test_server::RESUME_INCOMPLETE);
+ response->set_code(static_cast<net::HttpStatusCode>(308));
return response.PassAs<net::test_server::HttpResponse>();
}
« no previous file with comments | « chrome/browser/google_apis/drive_api_requests_unittest.cc ('k') | chrome/browser/google_apis/test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698