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 NET_TEST_BASE_TEST_SERVER_H_ | 5 #ifndef NET_TEST_BASE_TEST_SERVER_H_ |
6 #define NET_TEST_BASE_TEST_SERVER_H_ | 6 #define NET_TEST_BASE_TEST_SERVER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 TLSIntolerantLevel tls_intolerant; | 146 TLSIntolerantLevel tls_intolerant; |
147 }; | 147 }; |
148 | 148 |
149 // Pass as the 'host' parameter during construction to server on 127.0.0.1 | 149 // Pass as the 'host' parameter during construction to server on 127.0.0.1 |
150 static const char kLocalhost[]; | 150 static const char kLocalhost[]; |
151 | 151 |
152 // Initialize a TestServer listening on a specific host (IP or hostname). | 152 // Initialize a TestServer listening on a specific host (IP or hostname). |
153 BaseTestServer(Type type, const std::string& host); | 153 BaseTestServer(Type type, const std::string& host); |
154 | 154 |
155 // Initialize a TestServer with a specific set of SSLOptions for HTTPS or WSS. | 155 // Initialize a TestServer with a specific set of SSLOptions for HTTPS or WSS. |
156 explicit BaseTestServer(Type type, const SSLOptions& ssl_options); | 156 BaseTestServer(Type type, const SSLOptions& ssl_options); |
157 | 157 |
158 // Returns the host port pair used by current Python based test server only | 158 // Returns the host port pair used by current Python based test server only |
159 // if the server is started. | 159 // if the server is started. |
160 const HostPortPair& host_port_pair() const; | 160 const HostPortPair& host_port_pair() const; |
161 | 161 |
162 const FilePath& document_root() const { return document_root_; } | 162 const FilePath& document_root() const { return document_root_; } |
163 const base::DictionaryValue& server_data() const; | 163 const base::DictionaryValue& server_data() const; |
164 std::string GetScheme() const; | 164 std::string GetScheme() const; |
165 bool GetAddressList(AddressList* address_list) const WARN_UNUSED_RESULT; | 165 bool GetAddressList(AddressList* address_list) const WARN_UNUSED_RESULT; |
166 | 166 |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
250 bool log_to_console_; | 250 bool log_to_console_; |
251 | 251 |
252 scoped_ptr<ScopedPortException> allowed_port_; | 252 scoped_ptr<ScopedPortException> allowed_port_; |
253 | 253 |
254 DISALLOW_COPY_AND_ASSIGN(BaseTestServer); | 254 DISALLOW_COPY_AND_ASSIGN(BaseTestServer); |
255 }; | 255 }; |
256 | 256 |
257 } // namespace net | 257 } // namespace net |
258 | 258 |
259 #endif // NET_TEST_BASE_TEST_SERVER_H_ | 259 #endif // NET_TEST_BASE_TEST_SERVER_H_ |
260 | |
OLD | NEW |