| 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 "base/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/bind_helpers.h" | 6 #include "base/bind_helpers.h" |
| 7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
| 8 #include "base/run_loop.h" | 8 #include "base/run_loop.h" |
| 9 #include "base/synchronization/waitable_event.h" | 9 #include "base/synchronization/waitable_event.h" |
| 10 #include "components/navigation_interception/intercept_navigation_resource_throt
tle.h" | 10 #include "components/navigation_interception/intercept_navigation_resource_throt
tle.h" |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "content/public/test/mock_resource_context.h" | 24 #include "content/public/test/mock_resource_context.h" |
| 25 #include "content/public/test/test_renderer_host.h" | 25 #include "content/public/test/test_renderer_host.h" |
| 26 #include "net/base/request_priority.h" | 26 #include "net/base/request_priority.h" |
| 27 #include "net/http/http_response_headers.h" | 27 #include "net/http/http_response_headers.h" |
| 28 #include "net/http/http_response_info.h" | 28 #include "net/http/http_response_info.h" |
| 29 #include "net/url_request/url_request.h" | 29 #include "net/url_request/url_request.h" |
| 30 #include "net/url_request/url_request_test_util.h" | 30 #include "net/url_request/url_request_test_util.h" |
| 31 #include "testing/gmock/include/gmock/gmock.h" | 31 #include "testing/gmock/include/gmock/gmock.h" |
| 32 #include "testing/gtest/include/gtest/gtest.h" | 32 #include "testing/gtest/include/gtest/gtest.h" |
| 33 | 33 |
| 34 using content::ResourceType; |
| 34 using testing::_; | 35 using testing::_; |
| 35 using testing::Eq; | 36 using testing::Eq; |
| 36 using testing::Ne; | 37 using testing::Ne; |
| 37 using testing::Property; | 38 using testing::Property; |
| 38 using testing::Return; | 39 using testing::Return; |
| 39 | 40 |
| 40 namespace navigation_interception { | 41 namespace navigation_interception { |
| 41 | 42 |
| 42 namespace { | 43 namespace { |
| 43 | 44 |
| (...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 470 REDIRECT_MODE_302, | 471 REDIRECT_MODE_302, |
| 471 web_contents()->GetRenderViewHost()->GetProcess()->GetID(), | 472 web_contents()->GetRenderViewHost()->GetProcess()->GetID(), |
| 472 web_contents()->GetMainFrame()->GetRoutingID(), | 473 web_contents()->GetMainFrame()->GetRoutingID(), |
| 473 base::Unretained(&defer))); | 474 base::Unretained(&defer))); |
| 474 | 475 |
| 475 // Wait for the request to finish processing. | 476 // Wait for the request to finish processing. |
| 476 base::RunLoop().RunUntilIdle(); | 477 base::RunLoop().RunUntilIdle(); |
| 477 } | 478 } |
| 478 | 479 |
| 479 } // namespace navigation_interception | 480 } // namespace navigation_interception |
| OLD | NEW |