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

Side by Side Diff: chrome/test/remoting/me2me_browsertest.cc

Issue 398823005: Automate host start up in browser test (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/test/remoting/pin_browsertest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/file_util.h" 5 #include "base/file_util.h"
6 #include "base/files/file_path.h" 6 #include "base/files/file_path.h"
7 #include "chrome/test/remoting/remote_desktop_browsertest.h" 7 #include "chrome/test/remoting/remote_desktop_browsertest.h"
8 #include "chrome/test/remoting/waiter.h" 8 #include "chrome/test/remoting/waiter.h"
9 9
10 namespace remoting { 10 namespace remoting {
11 11
12 class Me2MeBrowserTest : public RemoteDesktopBrowserTest { 12 class Me2MeBrowserTest : public RemoteDesktopBrowserTest {
13 protected: 13 protected:
14 void TestKeyboardInput(); 14 void TestKeyboardInput();
15 void TestMouseInput(); 15 void TestMouseInput();
16 16
17 void ConnectPinlessAndCleanupPairings(bool cleanup_all); 17 void ConnectPinlessAndCleanupPairings(bool cleanup_all);
18 bool IsPairingSpinnerHidden(); 18 bool IsPairingSpinnerHidden();
19 bool WaitForFullscreenChange(bool expect_fullscreen); 19 bool WaitForFullscreenChange(bool expect_fullscreen);
20 }; 20 };
21 21
22 IN_PROC_BROWSER_TEST_F(Me2MeBrowserTest, 22 IN_PROC_BROWSER_TEST_F(Me2MeBrowserTest,
23 MANUAL_Me2Me_Connect_Local_Host) { 23 MANUAL_Me2Me_Connect_Local_Host) {
24 VerifyInternetAccess(); 24 SetUpTestForMe2Me();
25 Install();
26 LaunchChromotingApp();
27
28 // Authorize, Authenticate, and Approve.
29 Auth();
30 ExpandMe2Me();
31 25
32 ConnectToLocalHost(false); 26 ConnectToLocalHost(false);
33 27
34 // TODO(chaitali): Change the mouse input test to also work in the 28 // TODO(chaitali): Change the mouse input test to also work in the
35 // HTTP server framework 29 // HTTP server framework
36 // TestMouseInput(); 30 // TestMouseInput();
37 31
38 DisconnectMe2Me(); 32 DisconnectMe2Me();
39 Cleanup(); 33 Cleanup();
40 } 34 }
(...skipping 13 matching lines...) Expand all
54 // TODO(weitaosu): Find a way to verify keyboard input injection. 48 // TODO(weitaosu): Find a way to verify keyboard input injection.
55 // We cannot use TestKeyboardInput because it assumes 49 // We cannot use TestKeyboardInput because it assumes
56 // that the client and the host are on the same machine. 50 // that the client and the host are on the same machine.
57 51
58 DisconnectMe2Me(); 52 DisconnectMe2Me();
59 Cleanup(); 53 Cleanup();
60 } 54 }
61 55
62 IN_PROC_BROWSER_TEST_F(Me2MeBrowserTest, 56 IN_PROC_BROWSER_TEST_F(Me2MeBrowserTest,
63 MANUAL_Me2Me_Connect_Pinless) { 57 MANUAL_Me2Me_Connect_Pinless) {
64 VerifyInternetAccess(); 58 SetUpTestForMe2Me();
65 Install();
66 LaunchChromotingApp();
67
68 // Authorize, Authenticate, and Approve.
69 Auth();
70 ExpandMe2Me();
71 59
72 ASSERT_FALSE(HtmlElementVisible("paired-client-manager-message")) 60 ASSERT_FALSE(HtmlElementVisible("paired-client-manager-message"))
73 << "The host must have no pairings before running the pinless test."; 61 << "The host must have no pairings before running the pinless test.";
74 62
75 // Test that cleanup works with either the Delete or Delete all buttons. 63 // Test that cleanup works with either the Delete or Delete all buttons.
76 ConnectPinlessAndCleanupPairings(false); 64 ConnectPinlessAndCleanupPairings(false);
77 ConnectPinlessAndCleanupPairings(true); 65 ConnectPinlessAndCleanupPairings(true);
78 66
79 Cleanup(); 67 Cleanup();
80 } 68 }
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 ConditionalTimeoutWaiter waiter( 194 ConditionalTimeoutWaiter waiter(
207 base::TimeDelta::FromSeconds(10), 195 base::TimeDelta::FromSeconds(10),
208 base::TimeDelta::FromMilliseconds(500), 196 base::TimeDelta::FromMilliseconds(500),
209 base::Bind(&RemoteDesktopBrowserTest::IsHostActionComplete, 197 base::Bind(&RemoteDesktopBrowserTest::IsHostActionComplete,
210 active_web_contents(), 198 active_web_contents(),
211 javascript)); 199 javascript));
212 return waiter.Wait(); 200 return waiter.Wait();
213 } 201 }
214 202
215 } // namespace remoting 203 } // namespace remoting
OLDNEW
« no previous file with comments | « no previous file | chrome/test/remoting/pin_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698