Index: net/test/spawned_test_server/base_test_server.cc |
diff --git a/net/test/spawned_test_server/base_test_server.cc b/net/test/spawned_test_server/base_test_server.cc |
index c0fc6c5fc8f3e369b97c5864a9defaab2a6e90f7..26608c63bbd561d638a96a81b6d99afb2bd37acd 100644 |
--- a/net/test/spawned_test_server/base_test_server.cc |
+++ b/net/test/spawned_test_server/base_test_server.cc |
@@ -165,7 +165,8 @@ const char BaseTestServer::kLocalhost[] = "127.0.0.1"; |
BaseTestServer::BaseTestServer(Type type, const std::string& host) |
: type_(type), |
started_(false), |
- log_to_console_(false) { |
+ log_to_console_(false), |
+ ws_basic_auth_(false) { |
Init(host); |
} |
@@ -173,7 +174,8 @@ BaseTestServer::BaseTestServer(Type type, const SSLOptions& ssl_options) |
: ssl_options_(ssl_options), |
type_(type), |
started_(false), |
- log_to_console_(false) { |
+ log_to_console_(false), |
+ ws_basic_auth_(false) { |
DCHECK(UsingSSL(type)); |
Init(GetHostname(type, ssl_options)); |
} |
@@ -384,6 +386,11 @@ bool BaseTestServer::GenerateArguments(base::DictionaryValue* arguments) const { |
if (VLOG_IS_ON(1) || log_to_console_) |
arguments->Set("log-to-console", base::Value::CreateNullValue()); |
+ if (ws_basic_auth_) { |
+ DCHECK(type_ == TYPE_WS || type_ == TYPE_WSS); |
+ arguments->Set("ws-basic-auth", base::Value::CreateNullValue()); |
+ } |
+ |
if (UsingSSL(type_)) { |
// Check the certificate arguments of the HTTPS server. |
base::FilePath certificate_path(certificates_dir_); |