Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(649)

Unified Diff: net/test/test_server.cc

Issue 5239001: [Sync] Make sync integration tests use local xmpp servers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« chrome/test/live_sync/live_sync_test.cc ('K') | « net/test/test_server.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/test/test_server.cc
diff --git a/net/test/test_server.cc b/net/test/test_server.cc
index 1fd20c9fb12d6ea829a9771d5fd89b32d6d24274..69c87061dba06b4214df6f51a3c149ec56787e75 100644
--- a/net/test/test_server.cc
+++ b/net/test/test_server.cc
@@ -189,6 +189,11 @@ const HostPortPair& TestServer::host_port_pair() const {
return host_port_pair_;
}
+const DictionaryValue& TestServer::server_data() const {
+ DCHECK(started_);
+ return *server_data_;
+}
+
std::string TestServer::GetScheme() const {
switch (type_) {
case TYPE_FTP:
@@ -391,9 +396,9 @@ bool TestServer::ParseServerData(const std::string& server_data) {
<< json_reader.GetErrorMessage();
return false;
}
- DictionaryValue* dict = static_cast<DictionaryValue*>(value.get());
+ server_data_.reset(static_cast<DictionaryValue*>(value.release()));
int port = 0;
- if (!dict->GetInteger("port", &port)) {
+ if (!server_data_->GetInteger("port", &port)) {
LOG(ERROR) << "Could not find port value";
return false;
}
« chrome/test/live_sync/live_sync_test.cc ('K') | « net/test/test_server.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698