OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CONTENT_TEST_CONTENT_BROWSER_TEST_UTILS_H_ |
| 6 #define CONTENT_TEST_CONTENT_BROWSER_TEST_UTILS_H_ |
| 7 |
| 8 #include "googleurl/src/gurl.h" |
| 9 |
| 10 class FilePath; |
| 11 |
| 12 // A collections of functions designed for use with content_browsertests. |
| 13 // Note: if a function here also works with browser_tests, it should be in |
| 14 // content\public\test\browser_test_utils.h |
| 15 |
| 16 namespace content { |
| 17 |
| 18 class Shell; |
| 19 |
| 20 // Generate the file path for testing a particular test. |
| 21 // The file for the tests is all located in |
| 22 // content/test/data/dir/<file> |
| 23 // The returned path is FilePath format. |
| 24 FilePath GetTestFilePath(const char* dir, const char* file); |
| 25 |
| 26 // Generate the URL for testing a particular test. |
| 27 // HTML for the tests is all located in |
| 28 // test_root_directory/dir/<file> |
| 29 // The returned path is GURL format. |
| 30 GURL GetTestUrl(const char* dir, const char* file); |
| 31 |
| 32 // Navigates the selected tab of |window| to |url|, blocking until the |
| 33 // navigation finishes. |
| 34 void NavigateToURL(Shell* window, const GURL& url); |
| 35 |
| 36 } // namespace content |
| 37 |
| 38 #endif // CONTENT_TEST_CONTENT_BROWSER_TEST_UTILS_H_ |
OLD | NEW |