Fix flake in AddMediaToConnectedBundleDoesNotRestartIce test

EXPECT_EQ(0u, caller()->ice_connection_state_history().size());

Was failing since it cleared the connection state history before
the caller had finished transitioning to Completed, so the initial
transitions would be mistaken for later transitions.

Bug: None
Change-Id: I7043638f077ac5dcaeeca0d3ea6accc93c920364
Reviewed-on: https://webrtc-review.googlesource.com/16261
Reviewed-by: Peter Thatcher <pthatcher@webrtc.org>
Commit-Queue: Peter Thatcher <pthatcher@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#20570}
This commit is contained in:
Steve Anton 2017-10-26 12:24:50 -07:00 committed by Commit Bot
parent 12251b6386
commit ff52f1b91e

View File

@ -3124,6 +3124,8 @@ TEST_F(PeerConnectionIntegrationTest,
caller()->AddAudioOnlyMediaStream();
caller()->CreateAndSetAndSignalOffer();
ASSERT_TRUE_WAIT(SignalingStateStable(), kDefaultTimeout);
ASSERT_EQ_WAIT(PeerConnectionInterface::kIceConnectionCompleted,
caller()->ice_connection_state(), kDefaultTimeout);
caller()->clear_ice_connection_state_history();