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

Unified Diff: net/url_request/url_request_unittest.cc

Issue 9811006: Ignore Content-Length mismatches when Content-Length is too large. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Remove browser_tests Created 8 years, 9 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
« net/http/http_stream_parser.cc ('K') | « net/url_request/url_request_http_job.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/url_request_unittest.cc
diff --git a/net/url_request/url_request_unittest.cc b/net/url_request/url_request_unittest.cc
index f31f368a015af52281bfc932be60da25f15e904a..c64b6e450ccecdb12b7aaaeeb178465f3f84c5b2 100644
--- a/net/url_request/url_request_unittest.cc
+++ b/net/url_request/url_request_unittest.cc
@@ -1171,11 +1171,6 @@ TEST_F(URLRequestTestHTTP, GetZippedTest) {
// S - Small length (smaller than both C & U).
const char test_parameters[] = "CULMS";
const int num_tests = arraysize(test_parameters)- 1; // Skip NULL.
- // C & U should be OK.
- // L & M are larger than the data sent, and show an error.
- // S has too little data, but we seem to accept it.
- const bool test_expect_success[num_tests] =
- { true, true, false, false, true };
for (int i = 0; i < num_tests ; i++) {
TestDelegate d;
@@ -1202,14 +1197,8 @@ TEST_F(URLRequestTestHTTP, GetZippedTest) {
VLOG(1) << " Received " << d.bytes_received() << " bytes"
<< " status = " << r.status().status()
<< " error = " << r.status().error();
- if (test_expect_success[i]) {
- EXPECT_EQ(URLRequestStatus::SUCCESS, r.status().status())
- << " Parameter = \"" << test_file << "\"";
- } else {
- EXPECT_EQ(URLRequestStatus::FAILED, r.status().status());
- EXPECT_EQ(-100, r.status().error())
- << " Parameter = \"" << test_file << "\"";
- }
+ EXPECT_EQ(URLRequestStatus::SUCCESS, r.status().status())
+ << " Parameter = \"" << test_file << "\"";
}
}
}
« net/http/http_stream_parser.cc ('K') | « net/url_request/url_request_http_job.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698