OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "content/child/url_loader_client_impl.h" | 5 #include "content/child/url_loader_client_impl.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 #include "base/memory/ptr_util.h" | 8 #include "base/memory/ptr_util.h" |
9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
10 #include "base/run_loop.h" | 10 #include "base/run_loop.h" |
11 #include "content/child/resource_dispatcher.h" | 11 #include "content/child/resource_dispatcher.h" |
12 #include "content/child/test_request_peer.h" | 12 #include "content/child/test_request_peer.h" |
13 #include "content/common/url_loader_factory.mojom.h" | 13 #include "content/public/common/url_loader_factory.mojom.h" |
14 #include "ipc/ipc_sender.h" | 14 #include "ipc/ipc_sender.h" |
15 #include "mojo/public/cpp/bindings/associated_interface_ptr_info.h" | 15 #include "mojo/public/cpp/bindings/associated_interface_ptr_info.h" |
16 #include "mojo/public/cpp/bindings/binding.h" | 16 #include "mojo/public/cpp/bindings/binding.h" |
17 #include "net/traffic_annotation/network_traffic_annotation_test_helper.h" | 17 #include "net/traffic_annotation/network_traffic_annotation_test_helper.h" |
18 #include "net/url_request/redirect_info.h" | 18 #include "net/url_request/redirect_info.h" |
19 #include "testing/gtest/include/gtest/gtest.h" | 19 #include "testing/gtest/include/gtest/gtest.h" |
20 | 20 |
21 namespace content { | 21 namespace content { |
22 | 22 |
23 class URLLoaderClientImplTest : public ::testing::Test, | 23 class URLLoaderClientImplTest : public ::testing::Test, |
(...skipping 499 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
523 | 523 |
524 dispatcher_->SetDefersLoading(request_id_, false); | 524 dispatcher_->SetDefersLoading(request_id_, false); |
525 base::RunLoop().RunUntilIdle(); | 525 base::RunLoop().RunUntilIdle(); |
526 EXPECT_TRUE(request_peer_context_.received_response); | 526 EXPECT_TRUE(request_peer_context_.received_response); |
527 EXPECT_TRUE(request_peer_context_.complete); | 527 EXPECT_TRUE(request_peer_context_.complete); |
528 EXPECT_EQ(4, request_peer_context_.total_encoded_data_length); | 528 EXPECT_EQ(4, request_peer_context_.total_encoded_data_length); |
529 EXPECT_FALSE(request_peer_context_.cancelled); | 529 EXPECT_FALSE(request_peer_context_.cancelled); |
530 } | 530 } |
531 | 531 |
532 } // namespace content | 532 } // namespace content |
OLD | NEW |