Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(832)

Unified Diff: content/public/test/test_frame_navigation_observer.h

Issue 2478583005: Browser tests for starting a drag-and-drop out of an OOPIF. (Closed)
Patch Set: Rebasing... Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/public/test/test_frame_navigation_observer.h
diff --git a/content/test/test_frame_navigation_observer.h b/content/public/test/test_frame_navigation_observer.h
similarity index 80%
rename from content/test/test_frame_navigation_observer.h
rename to content/public/test/test_frame_navigation_observer.h
index 9e40ae71fc9c2bbc722c377e9f462b59a1030420..10b0b77affd6e71f9806092f152a5299998eaf75 100644
--- a/content/test/test_frame_navigation_observer.h
+++ b/content/public/test/test_frame_navigation_observer.h
@@ -12,22 +12,23 @@
#include "base/compiler_specific.h"
#include "base/macros.h"
#include "content/public/browser/web_contents_observer.h"
+#include "content/public/test/browser_test_utils.h"
#include "content/public/test/test_utils.h"
class GURL;
namespace content {
-class FrameTreeNode;
-class WebContents;
+class RenderFrameHost;
-// For content_browsertests, which run on the UI thread, run a second
-// MessageLoop and quit when the navigation in a specific frame (and all of its
-// subframes) has completed loading.
+// Helper for waiting until the navigation in a specific frame tree node (and
+// all of its subframes) has completed loading.
class TestFrameNavigationObserver : public WebContentsObserver {
public:
// Create and register a new TestFrameNavigationObserver which will track
- // navigations performed in the specified |node| of the frame tree.
- explicit TestFrameNavigationObserver(FrameTreeNode* node);
+ // navigations performed in the frame tree node associated with |adapter|.
+ // Note that RenderFrameHost associated with |frame| might be destroyed during
+ // the navigation (e.g. if the content commits in a new renderer process).
+ explicit TestFrameNavigationObserver(const ToRenderFrameHost& adapter);
~TestFrameNavigationObserver() override;
« no previous file with comments | « content/browser/web_contents/drag_and_drop_browsertest.cc ('k') | content/public/test/test_frame_navigation_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698