| 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 CHROME_BROWSER_EXTENSIONS_EXTENSION_APITEST_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_APITEST_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_APITEST_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_APITEST_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 // Allow manifest versions older that Extension::kModernManifestVersion. | 58 // Allow manifest versions older that Extension::kModernManifestVersion. |
| 59 // Used to test old manifest features. | 59 // Used to test old manifest features. |
| 60 kFlagAllowOldManifestVersions = 1 << 6, | 60 kFlagAllowOldManifestVersions = 1 << 6, |
| 61 }; | 61 }; |
| 62 | 62 |
| 63 ExtensionApiTest(); | 63 ExtensionApiTest(); |
| 64 ~ExtensionApiTest() override; | 64 ~ExtensionApiTest() override; |
| 65 | 65 |
| 66 protected: | 66 protected: |
| 67 // InProcessBrowserTest: | 67 // InProcessBrowserTest: |
| 68 void SetUpInProcessBrowserTestFixture() override; | 68 void SetUpOnMainThread() override; |
| 69 void TearDownInProcessBrowserTestFixture() override; | 69 void TearDownInProcessBrowserTestFixture() override; |
| 70 | 70 |
| 71 // Load |extension_name| and wait for pass / fail notification. | 71 // Load |extension_name| and wait for pass / fail notification. |
| 72 // |extension_name| is a directory in "test/data/extensions/api_test". | 72 // |extension_name| is a directory in "test/data/extensions/api_test". |
| 73 bool RunExtensionTest(const std::string& extension_name); | 73 bool RunExtensionTest(const std::string& extension_name); |
| 74 | 74 |
| 75 // Similar to RunExtensionTest, except sets an additional string argument | 75 // Similar to RunExtensionTest, except sets an additional string argument |
| 76 // |customArg| to the test config object. | 76 // |customArg| to the test config object. |
| 77 bool RunExtensionTestWithArg(const std::string& extension_name, | 77 bool RunExtensionTestWithArg(const std::string& extension_name, |
| 78 const char* custom_arg); | 78 const char* custom_arg); |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 std::unique_ptr<base::DictionaryValue> test_config_; | 201 std::unique_ptr<base::DictionaryValue> test_config_; |
| 202 | 202 |
| 203 // Hold the test WebSocket server. | 203 // Hold the test WebSocket server. |
| 204 std::unique_ptr<net::SpawnedTestServer> websocket_server_; | 204 std::unique_ptr<net::SpawnedTestServer> websocket_server_; |
| 205 | 205 |
| 206 // Hold the test FTP server. | 206 // Hold the test FTP server. |
| 207 std::unique_ptr<net::SpawnedTestServer> ftp_server_; | 207 std::unique_ptr<net::SpawnedTestServer> ftp_server_; |
| 208 }; | 208 }; |
| 209 | 209 |
| 210 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_APITEST_H_ | 210 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_APITEST_H_ |
| OLD | NEW |