| 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 #ifndef CONTENT_PUBLIC_TEST_WEB_CONTENTS_TESTER_H_ | 5 #ifndef CONTENT_PUBLIC_TEST_WEB_CONTENTS_TESTER_H_ |
| 6 #define CONTENT_PUBLIC_TEST_WEB_CONTENTS_TESTER_H_ | 6 #define CONTENT_PUBLIC_TEST_WEB_CONTENTS_TESTER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "content/public/browser/site_instance.h" | 10 #include "content/public/browser/site_instance.h" |
| 11 #include "ui/base/page_transition_types.h" | 11 #include "ui/base/page_transition_types.h" |
| 12 | 12 |
| 13 class GURL; | 13 class GURL; |
| 14 | 14 |
| 15 namespace content { | 15 namespace content { |
| 16 | 16 |
| 17 class BrowserContext; | 17 class BrowserContext; |
| 18 class NavigationData; |
| 19 class NavigationHandle; |
| 18 class RenderFrameHost; | 20 class RenderFrameHost; |
| 19 class RenderViewHost; | 21 class RenderViewHost; |
| 20 class WebContents; | 22 class WebContents; |
| 21 struct Referrer; | 23 struct Referrer; |
| 22 | 24 |
| 23 // This interface allows embedders of content/ to write tests that depend on a | 25 // This interface allows embedders of content/ to write tests that depend on a |
| 24 // test version of WebContents. This interface can be retrieved from any | 26 // test version of WebContents. This interface can be retrieved from any |
| 25 // WebContents that was retrieved via a call to | 27 // WebContents that was retrieved via a call to |
| 26 // RenderViewHostTestHarness::GetWebContents() (directly or indirectly) or | 28 // RenderViewHostTestHarness::GetWebContents() (directly or indirectly) or |
| 27 // constructed explicitly via CreateTestWebContents. | 29 // constructed explicitly via CreateTestWebContents. |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 const GURL& url, | 112 const GURL& url, |
| 111 ui::PageTransition transition) = 0; | 113 ui::PageTransition transition) = 0; |
| 112 virtual void TestDidNavigateWithReferrer(RenderFrameHost* render_frame_host, | 114 virtual void TestDidNavigateWithReferrer(RenderFrameHost* render_frame_host, |
| 113 int page_id, | 115 int page_id, |
| 114 int nav_entry_id, | 116 int nav_entry_id, |
| 115 bool did_create_new_entry, | 117 bool did_create_new_entry, |
| 116 const GURL& url, | 118 const GURL& url, |
| 117 const Referrer& referrer, | 119 const Referrer& referrer, |
| 118 ui::PageTransition transition) = 0; | 120 ui::PageTransition transition) = 0; |
| 119 | 121 |
| 122 // Sets NavgationData on |navigation_handle|. |
| 123 virtual void SetNavigationData( |
| 124 NavigationHandle* navigation_handle, |
| 125 std::unique_ptr<NavigationData> navigation_data) = 0; |
| 126 |
| 120 // Returns headers that were passed in the previous SaveFrameWithHeaders(...) | 127 // Returns headers that were passed in the previous SaveFrameWithHeaders(...) |
| 121 // call. | 128 // call. |
| 122 virtual const std::string& GetSaveFrameHeaders() = 0; | 129 virtual const std::string& GetSaveFrameHeaders() = 0; |
| 123 }; | 130 }; |
| 124 | 131 |
| 125 } // namespace content | 132 } // namespace content |
| 126 | 133 |
| 127 #endif // CONTENT_PUBLIC_TEST_WEB_CONTENTS_TESTER_H_ | 134 #endif // CONTENT_PUBLIC_TEST_WEB_CONTENTS_TESTER_H_ |
| OLD | NEW |