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

Unified Diff: net/url_request/url_request_ftp_job_unittest.cc

Issue 2265873002: Adjust callers and networking delegates in net/ to modified APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@URLRequestRead
Patch Set: rebased on top of URLRequest::Read CL Created 4 years, 3 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 | « net/url_request/url_request_file_dir_job_unittest.cc ('k') | net/url_request/url_request_http_job.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/url_request_ftp_job_unittest.cc
diff --git a/net/url_request/url_request_ftp_job_unittest.cc b/net/url_request/url_request_ftp_job_unittest.cc
index 9653617f19b158c96720377a689d47736a658a23..25ef8ba468df3845efaf0f6a3d3b553dff603f1b 100644
--- a/net/url_request/url_request_ftp_job_unittest.cc
+++ b/net/url_request/url_request_ftp_job_unittest.cc
@@ -309,7 +309,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequest) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_TRUE(url_request->proxy_server().Equals(
HostPortPair::FromString("localhost:80")));
EXPECT_EQ(1, network_delegate()->completed_requests());
@@ -405,7 +405,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestNeedProxyAuthNoCredentials) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_TRUE(url_request->proxy_server().Equals(
HostPortPair::FromString("localhost:80")));
EXPECT_EQ(1, network_delegate()->completed_requests());
@@ -451,7 +451,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestNeedProxyAuthWithCredentials) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_EQ(1, network_delegate()->completed_requests());
EXPECT_EQ(0, network_delegate()->error_count());
EXPECT_TRUE(request_delegate.auth_required_called());
@@ -484,7 +484,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestNeedServerAuthNoCredentials) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_EQ(1, network_delegate()->completed_requests());
EXPECT_EQ(0, network_delegate()->error_count());
EXPECT_TRUE(request_delegate.auth_required_called());
@@ -528,7 +528,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestNeedServerAuthWithCredentials) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_EQ(1, network_delegate()->completed_requests());
EXPECT_EQ(0, network_delegate()->error_count());
EXPECT_TRUE(request_delegate.auth_required_called());
@@ -602,7 +602,6 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestNeedProxyAndServerAuth) {
// Run until server auth is requested.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
EXPECT_EQ(0, network_delegate()->completed_requests());
EXPECT_EQ(0, network_delegate()->error_count());
url_request->SetAuth(
@@ -611,7 +610,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestNeedProxyAndServerAuth) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_EQ(1, network_delegate()->completed_requests());
EXPECT_EQ(0, network_delegate()->error_count());
EXPECT_TRUE(request_delegate.auth_required_called());
@@ -642,7 +641,7 @@ TEST_F(URLRequestFtpJobTest, FtpProxyRequestDoNotSaveCookies) {
// The TestDelegate will by default quit the message loop on completion.
base::RunLoop().Run();
- EXPECT_TRUE(url_request->status().is_success());
+ EXPECT_THAT(request_delegate.request_status(), IsOk());
EXPECT_EQ(1, network_delegate()->completed_requests());
EXPECT_EQ(0, network_delegate()->error_count());
« no previous file with comments | « net/url_request/url_request_file_dir_job_unittest.cc ('k') | net/url_request/url_request_http_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698