OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 NET_TEST_TEST_SERVER_H_ | 5 #ifndef NET_TEST_TEST_SERVER_H_ |
6 #define NET_TEST_TEST_SERVER_H_ | 6 #define NET_TEST_TEST_SERVER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 | 139 |
140 // Modify PYTHONPATH to contain libraries we need. | 140 // Modify PYTHONPATH to contain libraries we need. |
141 bool SetPythonPath() WARN_UNUSED_RESULT; | 141 bool SetPythonPath() WARN_UNUSED_RESULT; |
142 | 142 |
143 // Launches the Python test server. Returns true on success. | 143 // Launches the Python test server. Returns true on success. |
144 bool LaunchPython(const FilePath& testserver_path) WARN_UNUSED_RESULT; | 144 bool LaunchPython(const FilePath& testserver_path) WARN_UNUSED_RESULT; |
145 | 145 |
146 // Waits for the server to start. Returns true on success. | 146 // Waits for the server to start. Returns true on success. |
147 bool WaitToStart() WARN_UNUSED_RESULT; | 147 bool WaitToStart() WARN_UNUSED_RESULT; |
148 | 148 |
| 149 // Parses the server data read from the test server. Returns true |
| 150 // on success. |
| 151 bool ParseServerData(const std::string& server_data) WARN_UNUSED_RESULT; |
| 152 |
149 // Returns path to the root certificate. | 153 // Returns path to the root certificate. |
150 FilePath GetRootCertificatePath(); | 154 FilePath GetRootCertificatePath(); |
151 | 155 |
152 // Returns false if our test root certificate is not trusted. | 156 // Returns false if our test root certificate is not trusted. |
153 bool CheckCATrusted() WARN_UNUSED_RESULT; | 157 bool CheckCATrusted() WARN_UNUSED_RESULT; |
154 | 158 |
155 // Load the test root cert, if it hasn't been loaded yet. | 159 // Load the test root cert, if it hasn't been loaded yet. |
156 bool LoadTestRootCert() WARN_UNUSED_RESULT; | 160 bool LoadTestRootCert() WARN_UNUSED_RESULT; |
157 | 161 |
158 // Add the command line arguments for the Python test server to | 162 // Add the command line arguments for the Python test server to |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
199 | 203 |
200 // Has the server been started? | 204 // Has the server been started? |
201 bool started_; | 205 bool started_; |
202 | 206 |
203 DISALLOW_COPY_AND_ASSIGN(TestServer); | 207 DISALLOW_COPY_AND_ASSIGN(TestServer); |
204 }; | 208 }; |
205 | 209 |
206 } // namespace net | 210 } // namespace net |
207 | 211 |
208 #endif // NET_TEST_TEST_SERVER_H_ | 212 #endif // NET_TEST_TEST_SERVER_H_ |
OLD | NEW |