Index: google_apis/gcm/gcm_client_impl_unittest.cc |
diff --git a/google_apis/gcm/gcm_client_impl_unittest.cc b/google_apis/gcm/gcm_client_impl_unittest.cc |
index ba49590ba3686e225791047843beb26a0d14233c..f03f10e2f0d75d9b790c9f5e6f0069da15f625cc 100644 |
--- a/google_apis/gcm/gcm_client_impl_unittest.cc |
+++ b/google_apis/gcm/gcm_client_impl_unittest.cc |
@@ -236,19 +236,19 @@ class GCMClientImplTest : public testing::Test, |
// GCMClient::Delegate overrides (for verification). |
virtual void OnRegisterFinished(const std::string& app_id, |
const std::string& registration_id, |
- GCMClient::Result result) OVERRIDE; |
+ Result result) OVERRIDE; |
virtual void OnUnregisterFinished(const std::string& app_id, |
- GCMClient::Result result) OVERRIDE; |
+ Result result) OVERRIDE; |
virtual void OnSendFinished(const std::string& app_id, |
const std::string& message_id, |
- GCMClient::Result result) OVERRIDE {} |
+ Result result) OVERRIDE {} |
virtual void OnMessageReceived(const std::string& registration_id, |
- const GCMClient::IncomingMessage& message) |
+ const IncomingMessage& message) |
OVERRIDE; |
virtual void OnMessagesDeleted(const std::string& app_id) OVERRIDE; |
virtual void OnMessageSendError( |
const std::string& app_id, |
- const gcm::GCMClient::SendErrorDetails& send_error_details) OVERRIDE; |
+ const gcm::SendErrorDetails& send_error_details) OVERRIDE; |
virtual void OnGCMReady() OVERRIDE; |
GCMClientImpl* gcm_client() const { return gcm_client_.get(); } |
@@ -264,7 +264,7 @@ class GCMClientImplTest : public testing::Test, |
last_app_id_.clear(); |
last_registration_id_.clear(); |
last_message_id_.clear(); |
- last_result_ = GCMClient::UNKNOWN_ERROR; |
+ last_result_ = RESULT_UNKNOWN_ERROR; |
} |
LastEvent last_event() const { return last_event_; } |
@@ -273,11 +273,11 @@ class GCMClientImplTest : public testing::Test, |
return last_registration_id_; |
} |
const std::string& last_message_id() const { return last_message_id_; } |
- GCMClient::Result last_result() const { return last_result_; } |
- const GCMClient::IncomingMessage& last_message() const { |
+ Result last_result() const { return last_result_; } |
+ const IncomingMessage& last_message() const { |
return last_message_; |
} |
- const GCMClient::SendErrorDetails& last_error_details() const { |
+ const SendErrorDetails& last_error_details() const { |
return last_error_details_; |
} |
@@ -303,9 +303,9 @@ class GCMClientImplTest : public testing::Test, |
std::string last_app_id_; |
std::string last_registration_id_; |
std::string last_message_id_; |
- GCMClient::Result last_result_; |
- GCMClient::IncomingMessage last_message_; |
- GCMClient::SendErrorDetails last_error_details_; |
+ Result last_result_; |
+ IncomingMessage last_message_; |
+ SendErrorDetails last_error_details_; |
scoped_ptr<GCMClientImpl> gcm_client_; |
@@ -320,7 +320,7 @@ class GCMClientImplTest : public testing::Test, |
GCMClientImplTest::GCMClientImplTest() |
: last_event_(NONE), |
- last_result_(GCMClient::UNKNOWN_ERROR), |
+ last_result_(RESULT_UNKNOWN_ERROR), |
url_request_context_getter_(new net::TestURLRequestContextGetter( |
message_loop_.message_loop_proxy())) { |
} |
@@ -472,7 +472,7 @@ void GCMClientImplTest::OnGCMReady() { |
void GCMClientImplTest::OnMessageReceived( |
const std::string& registration_id, |
- const GCMClient::IncomingMessage& message) { |
+ const IncomingMessage& message) { |
last_event_ = MESSAGE_RECEIVED; |
last_app_id_ = registration_id; |
last_message_ = message; |
@@ -481,7 +481,7 @@ void GCMClientImplTest::OnMessageReceived( |
void GCMClientImplTest::OnRegisterFinished(const std::string& app_id, |
const std::string& registration_id, |
- GCMClient::Result result) { |
+ Result result) { |
last_event_ = REGISTRATION_COMPLETED; |
last_app_id_ = app_id; |
last_registration_id_ = registration_id; |
@@ -489,7 +489,7 @@ void GCMClientImplTest::OnRegisterFinished(const std::string& app_id, |
} |
void GCMClientImplTest::OnUnregisterFinished(const std::string& app_id, |
- GCMClient::Result result) { |
+ Result result) { |
last_event_ = UNREGISTRATION_COMPLETED; |
last_app_id_ = app_id; |
last_result_ = result; |
@@ -502,7 +502,7 @@ void GCMClientImplTest::OnMessagesDeleted(const std::string& app_id) { |
void GCMClientImplTest::OnMessageSendError( |
const std::string& app_id, |
- const gcm::GCMClient::SendErrorDetails& send_error_details) { |
+ const gcm::SendErrorDetails& send_error_details) { |
last_event_ = MESSAGE_SEND_ERROR; |
last_app_id_ = app_id; |
last_error_details_ = send_error_details; |
@@ -537,7 +537,7 @@ TEST_F(GCMClientImplTest, RegisterApp) { |
EXPECT_EQ(REGISTRATION_COMPLETED, last_event()); |
EXPECT_EQ(kAppId, last_app_id()); |
EXPECT_EQ("reg_id", last_registration_id()); |
- EXPECT_EQ(GCMClient::SUCCESS, last_result()); |
+ EXPECT_EQ(RESULT_SUCCESS, last_result()); |
EXPECT_TRUE(ExistsRegistration(kAppId)); |
} |
@@ -552,7 +552,7 @@ TEST_F(GCMClientImplTest, DISABLED_RegisterAppFromCache) { |
EXPECT_EQ(kAppId, last_app_id()); |
EXPECT_EQ("reg_id", last_registration_id()); |
- EXPECT_EQ(GCMClient::SUCCESS, last_result()); |
+ EXPECT_EQ(RESULT_SUCCESS, last_result()); |
EXPECT_EQ(REGISTRATION_COMPLETED, last_event()); |
// Recreate GCMClient in order to load from the persistent store. |
@@ -576,7 +576,7 @@ TEST_F(GCMClientImplTest, UnregisterApp) { |
EXPECT_EQ(UNREGISTRATION_COMPLETED, last_event()); |
EXPECT_EQ(kAppId, last_app_id()); |
- EXPECT_EQ(GCMClient::SUCCESS, last_result()); |
+ EXPECT_EQ(RESULT_SUCCESS, last_result()); |
EXPECT_FALSE(ExistsRegistration(kAppId)); |
} |
@@ -642,7 +642,7 @@ TEST_F(GCMClientImplTest, DispatchDownstreamMessageSendError) { |
EXPECT_EQ(kAppId, last_app_id()); |
EXPECT_EQ("007", last_error_details().message_id); |
EXPECT_EQ(1UL, last_error_details().additional_data.size()); |
- GCMClient::MessageData::const_iterator iter = |
+ MessageData::const_iterator iter = |
last_error_details().additional_data.find("error_details"); |
EXPECT_TRUE(iter != last_error_details().additional_data.end()); |
EXPECT_EQ("some details", iter->second); |
@@ -664,7 +664,7 @@ TEST_F(GCMClientImplTest, SendMessage) { |
mcs_proto::DataMessageStanza stanza; |
stanza.set_ttl(500); |
- GCMClient::OutgoingMessage message; |
+ OutgoingMessage message; |
message.id = "007"; |
message.time_to_live = 500; |
message.data["key"] = "value"; |