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

Unified Diff: chrome/browser/extensions/api/streams_private/streams_private_apitest.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
Index: chrome/browser/extensions/api/streams_private/streams_private_apitest.cc
diff --git a/chrome/browser/extensions/api/streams_private/streams_private_apitest.cc b/chrome/browser/extensions/api/streams_private/streams_private_apitest.cc
index 83e8c9009dc3408edb78ed698719f6e0ce4d1967..31393368a3a2eb0d6a8e8b39c136d8067eeebc95 100644
--- a/chrome/browser/extensions/api/streams_private/streams_private_apitest.cc
+++ b/chrome/browser/extensions/api/streams_private/streams_private_apitest.cc
@@ -51,7 +51,7 @@ scoped_ptr<HttpResponse> HandleRequest(const HttpRequest& request) {
// For relative path "/doc_path.doc", return success response with MIME type
// "application/msword".
if (request.relative_url == "/doc_path.doc") {
- response->set_code(net::test_server::SUCCESS);
+ response->set_code(net::HTTP_OK);
response->set_content_type("application/msword");
return response.PassAs<HttpResponse>();
}
@@ -60,7 +60,7 @@ scoped_ptr<HttpResponse> HandleRequest(const HttpRequest& request) {
// MIME type "plain/text" and content "txt content". Also, set content
// disposition to be attachment.
if (request.relative_url == "/text_path_attch.txt") {
- response->set_code(net::test_server::SUCCESS);
+ response->set_code(net::HTTP_OK);
response->set_content("txt content");
response->set_content_type("plain/text");
response->AddCustomHeader("Content-Disposition",
@@ -70,7 +70,7 @@ scoped_ptr<HttpResponse> HandleRequest(const HttpRequest& request) {
// For relative path "/test_path_attch.txt", return success response with
// MIME type "plain/text" and content "txt content".
if (request.relative_url == "/text_path.txt") {
- response->set_code(net::test_server::SUCCESS);
+ response->set_code(net::HTTP_OK);
response->set_content("txt content");
response->set_content_type("plain/text");
return response.PassAs<HttpResponse>();
@@ -78,7 +78,7 @@ scoped_ptr<HttpResponse> HandleRequest(const HttpRequest& request) {
// No other requests should be handled in the tests.
EXPECT_TRUE(false) << "NOTREACHED!";
- response->set_code(net::test_server::NOT_FOUND);
+ response->set_code(net::HTTP_NOT_FOUND);
return response.PassAs<HttpResponse>();
}

Powered by Google App Engine
This is Rietveld 408576698