Chromium Code Reviews| Index: chrome/test/remoting/remote_desktop_browsertest.h |
| diff --git a/chrome/test/remoting/remote_desktop_browsertest.h b/chrome/test/remoting/remote_desktop_browsertest.h |
| index 7ec09817c82b90a1f644b3595142b52d4d2cb76a..fe82578677d928d310f1d6676dea6f6162e46368 100644 |
| --- a/chrome/test/remoting/remote_desktop_browsertest.h |
| +++ b/chrome/test/remoting/remote_desktop_browsertest.h |
| @@ -91,7 +91,17 @@ class RemoteDesktopBrowserTest : public extensions::PlatformAppBrowserTest { |
| // until StartChromotingApp is invoked. Test code can execute arbitrary |
| // JavaScript in the context of the app between these two calls, for example |
| // to set up appropriate mocks. |
| + // |window_open_disposition| controls where the app will be launched. For v2 |
| + // app, the value of |window_open_disposition| will always be NEW_WINDOW. |
| + // Returns |app_web_content| that allow the caller to interact with the |
| + // content::WebContents of the launched app. The lifetime of |app_web_content| |
| + // is managed by LaunchChromotingApp(). |
| void LaunchChromotingApp(bool defer_start); |
| + void LaunchChromotingApp(bool defer_start, |
| + content::WebContents** app_web_content); |
|
Jamie
2015/01/10 00:14:24
Why not just return the WebContents pointer? It wo
kelvinp
2015/01/12 21:15:24
LaunchChromotingApp uses the ASSERT_MACRO which us
|
| + void LaunchChromotingApp(bool defer_start, |
| + WindowOpenDisposition window_open_disposition, |
| + content::WebContents** app_web_content); |
| // If the Chromoting app was launched in deferred mode, tell it to continue |
| // its regular start-up sequence. |
| @@ -144,9 +154,9 @@ class RemoteDesktopBrowserTest : public extensions::PlatformAppBrowserTest { |
| void Install(); |
| // Perform all necessary steps (installation, authorization, authentication, |
| - // expanding the me2me section) so that the app is ready for a me2me |
| - // connection. |
| - void SetUpTestForMe2Me(); |
| + // expanding the me2me section) so that the app is ready for a connection. |
| + // Returns the content::WebContents instance of the Chromoting app. |
| + content::WebContents* SetUpTest(); |
| // Clean up after the test. |
| void Cleanup(); |
| @@ -158,7 +168,7 @@ class RemoteDesktopBrowserTest : public extensions::PlatformAppBrowserTest { |
| // Ensures that the host is started locally with |me2me_pin()|. |
| // Browser_test.js must be loaded before calling this function. |
| - void EnsureRemoteConnectionEnabled(); |
| + void EnsureRemoteConnectionEnabled(content::WebContents* app_web_content); |
| // Connect to the local host through Me2Me. |
| void ConnectToLocalHost(bool remember_pin); |
| @@ -217,10 +227,6 @@ class RemoteDesktopBrowserTest : public extensions::PlatformAppBrowserTest { |
| return client_web_content_; |
| } |
| - content::WebContents* app_web_content() { |
| - return app_web_content_; |
| - } |
| - |
| // Whether to perform the cleanup tasks (uninstalling chromoting, etc). |
| // This is useful for diagnostic purposes. |
| bool NoCleanup() { return no_cleanup_; } |
| @@ -375,9 +381,6 @@ class RemoteDesktopBrowserTest : public extensions::PlatformAppBrowserTest { |
| // will get acknowledgments of actions completed on the host. |
| content::WebContents* client_web_content_; |
| - // WebContent of the landing page in the chromoting app. |
| - content::WebContents* app_web_content_; |
| - |
| bool no_cleanup_; |
| bool no_install_; |
| const Extension* extension_; |