| Index: blimp/net/engine_authentication_handler_unittest.cc
|
| diff --git a/blimp/net/engine_authentication_handler_unittest.cc b/blimp/net/engine_authentication_handler_unittest.cc
|
| index 9a3f4ca6c0bf01b57caae1fd2593d00d91045267..90fb7fdb9bac5dd4c12bd7f037b6bb58b6eba429 100644
|
| --- a/blimp/net/engine_authentication_handler_unittest.cc
|
| +++ b/blimp/net/engine_authentication_handler_unittest.cc
|
| @@ -41,11 +41,9 @@ class EngineAuthenticationHandlerTest : public testing::Test {
|
| protected:
|
| void ExpectOnConnection() {
|
| EXPECT_CALL(*connection_, SetConnectionErrorObserver(_))
|
| - .Times(2)
|
| - .WillRepeatedly(SaveArg<0>(&error_observer_));
|
| + .WillOnce(SaveArg<0>(&error_observer_));
|
| EXPECT_CALL(*connection_, SetIncomingMessageProcessor(_))
|
| - .Times(2)
|
| - .WillRepeatedly(SaveArg<0>(&incoming_message_processor_));
|
| + .WillOnce(SaveArg<0>(&incoming_message_processor_));
|
| }
|
|
|
| scoped_refptr<base::TestMockTimeTaskRunner> runner_;
|
| @@ -69,8 +67,6 @@ TEST_F(EngineAuthenticationHandlerTest, AuthenticationSucceeds) {
|
| incoming_message_processor_->ProcessMessage(std::move(blimp_message),
|
| process_message_cb.callback());
|
| EXPECT_EQ(net::OK, process_message_cb.WaitForResult());
|
| - EXPECT_EQ(nullptr, error_observer_);
|
| - EXPECT_EQ(nullptr, incoming_message_processor_);
|
| }
|
|
|
| TEST_F(EngineAuthenticationHandlerTest, WrongMessageReceived) {
|
| @@ -83,8 +79,6 @@ TEST_F(EngineAuthenticationHandlerTest, WrongMessageReceived) {
|
| incoming_message_processor_->ProcessMessage(std::move(blimp_message),
|
| process_message_cb.callback());
|
| EXPECT_EQ(net::OK, process_message_cb.WaitForResult());
|
| - EXPECT_EQ(nullptr, error_observer_);
|
| - EXPECT_EQ(nullptr, incoming_message_processor_);
|
| }
|
|
|
| TEST_F(EngineAuthenticationHandlerTest, ConnectionError) {
|
| @@ -93,8 +87,6 @@ TEST_F(EngineAuthenticationHandlerTest, ConnectionError) {
|
| EXPECT_NE(nullptr, error_observer_);
|
| EXPECT_NE(nullptr, incoming_message_processor_);
|
| error_observer_->OnConnectionError(net::ERR_FAILED);
|
| - EXPECT_EQ(nullptr, error_observer_);
|
| - EXPECT_EQ(nullptr, incoming_message_processor_);
|
| }
|
|
|
| TEST_F(EngineAuthenticationHandlerTest, Timeout) {
|
| @@ -104,8 +96,6 @@ TEST_F(EngineAuthenticationHandlerTest, Timeout) {
|
| EXPECT_NE(nullptr, incoming_message_processor_);
|
|
|
| runner_->FastForwardBy(base::TimeDelta::FromSeconds(11));
|
| - EXPECT_EQ(nullptr, error_observer_);
|
| - EXPECT_EQ(nullptr, incoming_message_processor_);
|
| }
|
|
|
| TEST_F(EngineAuthenticationHandlerTest, AuthHandlerDeletedFirst) {
|
|
|