| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CHROME_BROWSER_UI_WEBUI_WEB_UI_BROWSERTEST_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_WEB_UI_BROWSERTEST_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_WEB_UI_BROWSERTEST_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_WEB_UI_BROWSERTEST_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 bool RunJavascriptFunction(const std::string& function_name); | 52 bool RunJavascriptFunction(const std::string& function_name); |
| 53 bool RunJavascriptFunction(const std::string& function_name, | 53 bool RunJavascriptFunction(const std::string& function_name, |
| 54 const base::Value& arg); | 54 const base::Value& arg); |
| 55 bool RunJavascriptFunction(const std::string& function_name, | 55 bool RunJavascriptFunction(const std::string& function_name, |
| 56 const base::Value& arg1, | 56 const base::Value& arg1, |
| 57 const base::Value& arg2); | 57 const base::Value& arg2); |
| 58 bool RunJavascriptFunction(const std::string& function_name, | 58 bool RunJavascriptFunction(const std::string& function_name, |
| 59 const ConstValueVector& function_arguments); | 59 const ConstValueVector& function_arguments); |
| 60 | 60 |
| 61 // Runs a test fixture that may include calls to functions in test_api.js. | 61 // Runs a test fixture that may include calls to functions in test_api.js. |
| 62 bool RunJavascriptTestF(const std::string& test_fixture, | 62 bool RunJavascriptTestF(bool is_async, |
| 63 const std::string& test_fixture, |
| 63 const std::string& test_name); | 64 const std::string& test_name); |
| 64 | 65 |
| 65 // Runs a test that may include calls to functions in test_api.js. | 66 // Runs a test that may include calls to functions in test_api.js. |
| 66 bool RunJavascriptTest(const std::string& test_name); | 67 bool RunJavascriptTest(const std::string& test_name); |
| 67 bool RunJavascriptTest(const std::string& test_name, | 68 bool RunJavascriptTest(const std::string& test_name, |
| 68 const base::Value& arg); | 69 const base::Value& arg); |
| 69 bool RunJavascriptTest(const std::string& test_name, | 70 bool RunJavascriptTest(const std::string& test_name, |
| 70 const base::Value& arg1, | 71 const base::Value& arg1, |
| 71 const base::Value& arg2); | 72 const base::Value& arg2); |
| 72 bool RunJavascriptTest(const std::string& test_name, | 73 bool RunJavascriptTest(const std::string& test_name, |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 // again. | 162 // again. |
| 162 bool libraries_preloaded_; | 163 bool libraries_preloaded_; |
| 163 | 164 |
| 164 // Saves the states of |test_fixture| and |test_name| for calling | 165 // Saves the states of |test_fixture| and |test_name| for calling |
| 165 // PreloadJavascriptLibraries(). | 166 // PreloadJavascriptLibraries(). |
| 166 std::string preload_test_fixture_; | 167 std::string preload_test_fixture_; |
| 167 std::string preload_test_name_; | 168 std::string preload_test_name_; |
| 168 }; | 169 }; |
| 169 | 170 |
| 170 #endif // CHROME_BROWSER_UI_WEBUI_WEB_UI_BROWSERTEST_H_ | 171 #endif // CHROME_BROWSER_UI_WEBUI_WEB_UI_BROWSERTEST_H_ |
| OLD | NEW |