| 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/browser/loader/url_loader_factory_impl.h" | 5 #include "content/browser/loader/url_loader_factory_impl.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 // If browser side navigation is enabled then | 80 // If browser side navigation is enabled then |
| 81 // ResourceDispatcherHostImpl prevents main frame URL requests from | 81 // ResourceDispatcherHostImpl prevents main frame URL requests from |
| 82 // the renderer. Ensure that these checks don't trip us up by | 82 // the renderer. Ensure that these checks don't trip us up by |
| 83 // setting the process type in ResourceMessageFilter as | 83 // setting the process type in ResourceMessageFilter as |
| 84 // PROCESS_TYPE_UNKNOWN. | 84 // PROCESS_TYPE_UNKNOWN. |
| 85 PROCESS_TYPE_UNKNOWN, | 85 PROCESS_TYPE_UNKNOWN, |
| 86 nullptr, | 86 nullptr, |
| 87 nullptr, | 87 nullptr, |
| 88 nullptr, | 88 nullptr, |
| 89 nullptr, | 89 nullptr, |
| 90 nullptr, | |
| 91 base::Bind(&URLLoaderFactoryImplTest::GetContexts, | 90 base::Bind(&URLLoaderFactoryImplTest::GetContexts, |
| 92 base::Unretained(this)))) { | 91 base::Unretained(this)))) { |
| 93 MojoAsyncResourceHandler::SetAllocationSizeForTesting(GetParam()); | 92 MojoAsyncResourceHandler::SetAllocationSizeForTesting(GetParam()); |
| 94 rdh_.SetLoaderDelegate(&loader_deleate_); | 93 rdh_.SetLoaderDelegate(&loader_deleate_); |
| 95 | 94 |
| 96 URLLoaderFactoryImpl::Create(resource_message_filter_, | 95 URLLoaderFactoryImpl::Create(resource_message_filter_, |
| 97 mojo::GetProxy(&factory_)); | 96 mojo::GetProxy(&factory_)); |
| 98 | 97 |
| 99 // Calling this function creates a request context. | 98 // Calling this function creates a request context. |
| 100 browser_context_->GetResourceContext()->GetRequestContext(); | 99 browser_context_->GetResourceContext()->GetRequestContext(); |
| (...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 243 EXPECT_EQ(net::ERR_ABORTED, client.completion_status().error_code); | 242 EXPECT_EQ(net::ERR_ABORTED, client.completion_status().error_code); |
| 244 } | 243 } |
| 245 | 244 |
| 246 INSTANTIATE_TEST_CASE_P(URLLoaderFactoryImplTest, | 245 INSTANTIATE_TEST_CASE_P(URLLoaderFactoryImplTest, |
| 247 URLLoaderFactoryImplTest, | 246 URLLoaderFactoryImplTest, |
| 248 ::testing::Values(128, 32 * 1024)); | 247 ::testing::Values(128, 32 * 1024)); |
| 249 | 248 |
| 250 } // namespace | 249 } // namespace |
| 251 | 250 |
| 252 } // namespace content | 251 } // namespace content |
| OLD | NEW |