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/path_service.h" | 5 #include "base/path_service.h" |
6 #include "base/strings/utf_string_conversions.h" | 6 #include "base/strings/utf_string_conversions.h" |
7 #include "base/time/time.h" | 7 #include "base/time/time.h" |
8 #include "base/values.h" | 8 #include "base/values.h" |
9 #include "content/browser/frame_host/render_frame_host_impl.h" | 9 #include "content/browser/frame_host/render_frame_host_impl.h" |
10 #include "content/browser/renderer_host/render_view_host_impl.h" | 10 #include "content/browser/renderer_host/render_view_host_impl.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 | 31 |
32 class RenderViewHostTestWebContentsObserver : public WebContentsObserver { | 32 class RenderViewHostTestWebContentsObserver : public WebContentsObserver { |
33 public: | 33 public: |
34 explicit RenderViewHostTestWebContentsObserver(WebContents* web_contents) | 34 explicit RenderViewHostTestWebContentsObserver(WebContents* web_contents) |
35 : WebContentsObserver(web_contents), | 35 : WebContentsObserver(web_contents), |
36 navigation_count_(0) {} | 36 navigation_count_(0) {} |
37 virtual ~RenderViewHostTestWebContentsObserver() {} | 37 virtual ~RenderViewHostTestWebContentsObserver() {} |
38 | 38 |
39 virtual void DidNavigateMainFrame( | 39 virtual void DidNavigateMainFrame( |
40 const LoadCommittedDetails& details, | 40 const LoadCommittedDetails& details, |
41 const FrameNavigateParams& params) OVERRIDE { | 41 const FrameNavigateParams& params) override { |
42 observed_socket_address_ = params.socket_address; | 42 observed_socket_address_ = params.socket_address; |
43 base_url_ = params.base_url; | 43 base_url_ = params.base_url; |
44 ++navigation_count_; | 44 ++navigation_count_; |
45 } | 45 } |
46 | 46 |
47 const net::HostPortPair& observed_socket_address() const { | 47 const net::HostPortPair& observed_socket_address() const { |
48 return observed_socket_address_; | 48 return observed_socket_address_; |
49 } | 49 } |
50 | 50 |
51 GURL base_url() const { | 51 GURL base_url() const { |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 | 155 |
156 // Do something that causes ipc queues to flush and tasks in | 156 // Do something that causes ipc queues to flush and tasks in |
157 // flight to complete such that we should have received the ACK. | 157 // flight to complete such that we should have received the ACK. |
158 NavigateToURL(shell(), test_url); | 158 NavigateToURL(shell(), test_url); |
159 | 159 |
160 // Verify we have the only remaining reference to the namespace. | 160 // Verify we have the only remaining reference to the namespace. |
161 EXPECT_TRUE(session_namespace->HasOneRef()); | 161 EXPECT_TRUE(session_namespace->HasOneRef()); |
162 } | 162 } |
163 | 163 |
164 } // namespace content | 164 } // namespace content |
OLD | NEW |