| 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_BROWSER_TEST_UTILS_H_ | 5 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ |
| 6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ | 6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ |
| 7 | 7 |
| 8 #include <queue> | 8 #include <queue> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 class WebContents; | 50 class WebContents; |
| 51 | 51 |
| 52 // Generate a URL for a file path including a query string. | 52 // Generate a URL for a file path including a query string. |
| 53 GURL GetFileUrlWithQuery(const base::FilePath& path, | 53 GURL GetFileUrlWithQuery(const base::FilePath& path, |
| 54 const std::string& query_string); | 54 const std::string& query_string); |
| 55 | 55 |
| 56 // Waits for a load stop for the specified |web_contents|'s controller, if the | 56 // Waits for a load stop for the specified |web_contents|'s controller, if the |
| 57 // tab is currently web_contents. Otherwise returns immediately. | 57 // tab is currently web_contents. Otherwise returns immediately. |
| 58 void WaitForLoadStop(WebContents* web_contents); | 58 void WaitForLoadStop(WebContents* web_contents); |
| 59 | 59 |
| 60 void WaitForResizeComplete(WebContents* web_contents); |
| 61 |
| 60 // Causes the specified web_contents to crash. Blocks until it is crashed. | 62 // Causes the specified web_contents to crash. Blocks until it is crashed. |
| 61 void CrashTab(WebContents* web_contents); | 63 void CrashTab(WebContents* web_contents); |
| 62 | 64 |
| 63 // Simulates clicking at the center of the given tab asynchronously; modifiers | 65 // Simulates clicking at the center of the given tab asynchronously; modifiers |
| 64 // may contain bits from WebInputEvent::Modifiers. | 66 // may contain bits from WebInputEvent::Modifiers. |
| 65 void SimulateMouseClick(WebContents* web_contents, | 67 void SimulateMouseClick(WebContents* web_contents, |
| 66 int modifiers, | 68 int modifiers, |
| 67 blink::WebMouseEvent::Button button); | 69 blink::WebMouseEvent::Button button); |
| 68 | 70 |
| 69 // Simulates clicking at the point |point| of the given tab asynchronously; | 71 // Simulates clicking at the point |point| of the given tab asynchronously; |
| (...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 292 NotificationRegistrar registrar_; | 294 NotificationRegistrar registrar_; |
| 293 std::queue<std::string> message_queue_; | 295 std::queue<std::string> message_queue_; |
| 294 scoped_refptr<MessageLoopRunner> message_loop_runner_; | 296 scoped_refptr<MessageLoopRunner> message_loop_runner_; |
| 295 | 297 |
| 296 DISALLOW_COPY_AND_ASSIGN(DOMMessageQueue); | 298 DISALLOW_COPY_AND_ASSIGN(DOMMessageQueue); |
| 297 }; | 299 }; |
| 298 | 300 |
| 299 } // namespace content | 301 } // namespace content |
| 300 | 302 |
| 301 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ | 303 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ |
| OLD | NEW |