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

Side by Side Diff: net/http/http_response_body_drainer_unittest.cc

Issue 12680003: net: split net/ssl out of net/base (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/http/http_proxy_client_socket_pool.cc ('k') | net/http/http_response_info.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <cstring> 7 #include <cstring>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
11 #include "base/memory/weak_ptr.h" 11 #include "base/memory/weak_ptr.h"
12 #include "base/message_loop.h" 12 #include "base/message_loop.h"
13 #include "net/base/io_buffer.h" 13 #include "net/base/io_buffer.h"
14 #include "net/base/net_errors.h" 14 #include "net/base/net_errors.h"
15 #include "net/base/ssl_config_service_defaults.h"
16 #include "net/base/test_completion_callback.h" 15 #include "net/base/test_completion_callback.h"
17 #include "net/http/http_network_session.h" 16 #include "net/http/http_network_session.h"
18 #include "net/http/http_server_properties_impl.h" 17 #include "net/http/http_server_properties_impl.h"
19 #include "net/http/http_stream.h" 18 #include "net/http/http_stream.h"
20 #include "net/proxy/proxy_service.h" 19 #include "net/proxy/proxy_service.h"
20 #include "net/ssl/ssl_config_service_defaults.h"
21 #include "testing/gtest/include/gtest/gtest.h" 21 #include "testing/gtest/include/gtest/gtest.h"
22 22
23 namespace net { 23 namespace net {
24 24
25 namespace { 25 namespace {
26 26
27 const int kMagicChunkSize = 1024; 27 const int kMagicChunkSize = 1024;
28 COMPILE_ASSERT( 28 COMPILE_ASSERT(
29 (HttpResponseBodyDrainer::kDrainBodyBufferSize % kMagicChunkSize) == 0, 29 (HttpResponseBodyDrainer::kDrainBodyBufferSize % kMagicChunkSize) == 0,
30 chunk_size_needs_to_divide_evenly_into_buffer_size); 30 chunk_size_needs_to_divide_evenly_into_buffer_size);
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
316 316
317 TEST_F(HttpResponseBodyDrainerTest, StartWithNothingToDo) { 317 TEST_F(HttpResponseBodyDrainerTest, StartWithNothingToDo) {
318 mock_stream_->set_num_chunks(0); 318 mock_stream_->set_num_chunks(0);
319 drainer_->StartWithSize(session_, 0); 319 drainer_->StartWithSize(session_, 0);
320 EXPECT_FALSE(result_waiter_.WaitForResult()); 320 EXPECT_FALSE(result_waiter_.WaitForResult());
321 } 321 }
322 322
323 } // namespace 323 } // namespace
324 324
325 } // namespace net 325 } // namespace net
OLDNEW
« no previous file with comments | « net/http/http_proxy_client_socket_pool.cc ('k') | net/http/http_response_info.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698