Index: jingle/notifier/listener/xmpp_push_client_unittest.cc |
diff --git a/jingle/notifier/listener/xmpp_push_client_unittest.cc b/jingle/notifier/listener/xmpp_push_client_unittest.cc |
index 6a92bcfb4d148d0b51a93645bb20379428bc14f8..857e437b608310f2231f847c0fb683bbc95f4e3c 100644 |
--- a/jingle/notifier/listener/xmpp_push_client_unittest.cc |
+++ b/jingle/notifier/listener/xmpp_push_client_unittest.cc |
@@ -24,7 +24,7 @@ using ::testing::StrictMock; |
class MockObserver : public PushClientObserver { |
public: |
- MOCK_METHOD1(OnNotificationStateChange, void(bool)); |
+ MOCK_METHOD1(OnPushClientStateChange, void(PushClientState)); |
MOCK_METHOD1(OnIncomingNotification, void(const Notification&)); |
}; |
@@ -67,7 +67,7 @@ TEST_F(XmppPushClientTest, OnIncomingNotification) { |
// Make sure the XMPP push client notifies its observers of a |
// successful connection properly. |
TEST_F(XmppPushClientTest, ConnectAndSubscribe) { |
- EXPECT_CALL(mock_observer_, OnNotificationStateChange(true)); |
+ EXPECT_CALL(mock_observer_, OnPushClientStateChange(NOTIFICATIONS_ON)); |
xmpp_push_client_->OnConnect(fake_base_task_.AsWeakPtr()); |
xmpp_push_client_->OnSubscribed(); |
} |
@@ -75,14 +75,14 @@ TEST_F(XmppPushClientTest, ConnectAndSubscribe) { |
// Make sure the XMPP push client notifies its observers of a |
// terminated connection properly. |
TEST_F(XmppPushClientTest, Disconnect) { |
- EXPECT_CALL(mock_observer_, OnNotificationStateChange(false)); |
+ EXPECT_CALL(mock_observer_, OnPushClientStateChange(NOTIFICATIONS_OFF)); |
xmpp_push_client_->OnDisconnect(); |
} |
// Make sure the XMPP push client notifies its observers of a |
// subscription error properly. |
TEST_F(XmppPushClientTest, SubscriptionError) { |
- EXPECT_CALL(mock_observer_, OnNotificationStateChange(false)); |
+ EXPECT_CALL(mock_observer_, OnPushClientStateChange(NOTIFICATIONS_OFF)); |
xmpp_push_client_->OnSubscriptionError(); |
} |
@@ -92,7 +92,7 @@ TEST_F(XmppPushClientTest, SubscriptionError) { |
// TODO(akalin): Figure out how to test that the notification was |
// actually sent. |
TEST_F(XmppPushClientTest, SendNotification) { |
- EXPECT_CALL(mock_observer_, OnNotificationStateChange(true)); |
+ EXPECT_CALL(mock_observer_, OnPushClientStateChange(NOTIFICATIONS_ON)); |
xmpp_push_client_->OnConnect(fake_base_task_.AsWeakPtr()); |
xmpp_push_client_->OnSubscribed(); |
@@ -109,7 +109,7 @@ TEST_F(XmppPushClientTest, SendNotificationPending) { |
Mock::VerifyAndClearExpectations(&mock_observer_); |
- EXPECT_CALL(mock_observer_, OnNotificationStateChange(true)); |
+ EXPECT_CALL(mock_observer_, OnPushClientStateChange(NOTIFICATIONS_ON)); |
xmpp_push_client_->OnConnect(fake_base_task_.AsWeakPtr()); |
xmpp_push_client_->OnSubscribed(); |