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

Unified Diff: remoting/host/heartbeat_sender_unittest.cc

Issue 11364031: remoting: Update calls froms RunAllPending() to RunUntilIdle(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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
« no previous file with comments | « no previous file | remoting/host/host_key_pair_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/heartbeat_sender_unittest.cc
diff --git a/remoting/host/heartbeat_sender_unittest.cc b/remoting/host/heartbeat_sender_unittest.cc
index 63b4499298c8e884da7d426ef43dc1438448768e..4d050d7d62def1f23678bb428fe8f2d824aa30fe 100644
--- a/remoting/host/heartbeat_sender_unittest.cc
+++ b/remoting/host/heartbeat_sender_unittest.cc
@@ -98,14 +98,14 @@ TEST_F(HeartbeatSenderTest, DoSendStanza) {
.WillOnce(DoAll(SaveArg<0>(&sent_iq), Return(true)));
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::CONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
scoped_ptr<XmlElement> stanza(sent_iq);
ASSERT_TRUE(stanza != NULL);
ValidateHeartbeatStanza(stanza.get(), "0");
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::DISCONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
}
// Call Start() followed by Stop(), twice, and make sure two valid heartbeats
@@ -120,14 +120,14 @@ TEST_F(HeartbeatSenderTest, DoSendStanzaTwice) {
.WillOnce(DoAll(SaveArg<0>(&sent_iq), Return(true)));
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::CONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
scoped_ptr<XmlElement> stanza(sent_iq);
ASSERT_TRUE(stanza != NULL);
ValidateHeartbeatStanza(stanza.get(), "0");
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::DISCONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
EXPECT_CALL(signal_strategy_, GetLocalJid())
.WillRepeatedly(Return(kTestJid));
@@ -137,13 +137,13 @@ TEST_F(HeartbeatSenderTest, DoSendStanzaTwice) {
.WillOnce(DoAll(SaveArg<0>(&sent_iq), Return(true)));
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::CONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
scoped_ptr<XmlElement> stanza2(sent_iq);
ValidateHeartbeatStanza(stanza2.get(), "1");
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::DISCONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
}
// Call Start() followed by Stop(), make sure a valid Iq stanza is sent,
@@ -159,7 +159,7 @@ TEST_F(HeartbeatSenderTest, DoSendStanzaWithExpectedSequenceId) {
.WillOnce(DoAll(SaveArg<0>(&sent_iq), Return(true)));
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::CONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
scoped_ptr<XmlElement> stanza(sent_iq);
ASSERT_TRUE(stanza != NULL);
@@ -184,7 +184,7 @@ TEST_F(HeartbeatSenderTest, DoSendStanzaWithExpectedSequenceId) {
const int kExpectedSequenceId = 456;
expected_sequence_id->AddText(base::IntToString(kExpectedSequenceId));
heartbeat_sender_->ProcessResponse(NULL, response.get());
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
scoped_ptr<XmlElement> stanza2(sent_iq2);
ASSERT_TRUE(stanza2 != NULL);
@@ -192,7 +192,7 @@ TEST_F(HeartbeatSenderTest, DoSendStanzaWithExpectedSequenceId) {
base::IntToString(kExpectedSequenceId).c_str());
heartbeat_sender_->OnSignalStrategyStateChange(SignalStrategy::DISCONNECTED);
- message_loop_.RunAllPending();
+ message_loop_.RunUntilIdle();
}
// Verify that ProcessResponse parses set-interval result.
« no previous file with comments | « no previous file | remoting/host/host_key_pair_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698