OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "net/test/remote_test_server.h" | 5 #include "net/test/remote_test_server.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/base_paths.h" | 9 #include "base/base_paths.h" |
10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 std::string server_data; | 123 std::string server_data; |
124 base::JSONWriter::Write(&server_data_dict, &server_data); | 124 base::JSONWriter::Write(&server_data_dict, &server_data); |
125 if (server_data.empty() || !ParseServerData(server_data)) { | 125 if (server_data.empty() || !ParseServerData(server_data)) { |
126 LOG(ERROR) << "Could not parse server_data: " << server_data; | 126 LOG(ERROR) << "Could not parse server_data: " << server_data; |
127 return false; | 127 return false; |
128 } | 128 } |
129 | 129 |
130 return SetupWhenServerStarted(); | 130 return SetupWhenServerStarted(); |
131 } | 131 } |
132 | 132 |
| 133 bool RemoteTestServer::StartInBackground() { |
| 134 NOTIMPLEMENTED(); |
| 135 return false; |
| 136 } |
| 137 |
| 138 bool RemoteTestServer::BlockUntilStarted() { |
| 139 NOTIMPLEMENTED(); |
| 140 return false; |
| 141 } |
| 142 |
133 bool RemoteTestServer::Stop() { | 143 bool RemoteTestServer::Stop() { |
134 if (!spawner_communicator_.get()) | 144 if (!spawner_communicator_.get()) |
135 return true; | 145 return true; |
136 CleanUpWhenStoppingServer(); | 146 CleanUpWhenStoppingServer(); |
137 bool stopped = spawner_communicator_->StopServer(); | 147 bool stopped = spawner_communicator_->StopServer(); |
138 // Explicitly reset |spawner_communicator_| to avoid reusing the stopped one. | 148 // Explicitly reset |spawner_communicator_| to avoid reusing the stopped one. |
139 spawner_communicator_.reset(NULL); | 149 spawner_communicator_.reset(NULL); |
140 return stopped; | 150 return stopped; |
141 } | 151 } |
142 | 152 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 | 195 |
186 SetResourcePath(document_root, FilePath().AppendASCII("net") | 196 SetResourcePath(document_root, FilePath().AppendASCII("net") |
187 .AppendASCII("data") | 197 .AppendASCII("data") |
188 .AppendASCII("ssl") | 198 .AppendASCII("ssl") |
189 .AppendASCII("certificates")); | 199 .AppendASCII("certificates")); |
190 return true; | 200 return true; |
191 } | 201 } |
192 | 202 |
193 } // namespace net | 203 } // namespace net |
194 | 204 |
OLD | NEW |