OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "net/http/http_response_body_drainer.h" | 5 #include "net/http/http_response_body_drainer.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include <cstring> | 9 #include <cstring> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
13 #include "base/location.h" | 13 #include "base/location.h" |
| 14 #include "base/macros.h" |
14 #include "base/memory/weak_ptr.h" | 15 #include "base/memory/weak_ptr.h" |
15 #include "base/message_loop/message_loop.h" | 16 #include "base/message_loop/message_loop.h" |
16 #include "base/single_thread_task_runner.h" | 17 #include "base/single_thread_task_runner.h" |
17 #include "base/thread_task_runner_handle.h" | 18 #include "base/thread_task_runner_handle.h" |
18 #include "net/base/io_buffer.h" | 19 #include "net/base/io_buffer.h" |
19 #include "net/base/net_errors.h" | 20 #include "net/base/net_errors.h" |
20 #include "net/base/test_completion_callback.h" | 21 #include "net/base/test_completion_callback.h" |
21 #include "net/http/http_network_session.h" | 22 #include "net/http/http_network_session.h" |
22 #include "net/http/http_server_properties_impl.h" | 23 #include "net/http/http_server_properties_impl.h" |
23 #include "net/http/http_stream.h" | 24 #include "net/http/http_stream.h" |
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
305 too_many_chunks += 1; // Now it's too large. | 306 too_many_chunks += 1; // Now it's too large. |
306 | 307 |
307 mock_stream_->set_num_chunks(too_many_chunks); | 308 mock_stream_->set_num_chunks(too_many_chunks); |
308 drainer_->Start(session_.get()); | 309 drainer_->Start(session_.get()); |
309 EXPECT_TRUE(result_waiter_.WaitForResult()); | 310 EXPECT_TRUE(result_waiter_.WaitForResult()); |
310 } | 311 } |
311 | 312 |
312 } // namespace | 313 } // namespace |
313 | 314 |
314 } // namespace net | 315 } // namespace net |
OLD | NEW |