OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 void OnIceGatheringChange( | 165 void OnIceGatheringChange( |
166 PeerConnectionInterface::IceGatheringState new_state) override { | 166 PeerConnectionInterface::IceGatheringState new_state) override { |
167 // We can never transition back to "new". | 167 // We can never transition back to "new". |
168 EXPECT_NE(PeerConnectionInterface::kIceGatheringNew, new_state); | 168 EXPECT_NE(PeerConnectionInterface::kIceGatheringNew, new_state); |
169 ice_gathering_state_ = new_state; | 169 ice_gathering_state_ = new_state; |
170 oncandidatesready_ = | 170 oncandidatesready_ = |
171 new_state == PeerConnectionInterface::kIceGatheringComplete; | 171 new_state == PeerConnectionInterface::kIceGatheringComplete; |
172 } | 172 } |
173 | 173 |
174 // Found a new candidate. | 174 // Found a new candidate. |
175 void OnIceCandidate(const webrtc::IceCandidateInterface* candidate) override { | 175 void OnIceCandidate( |
| 176 std::unique_ptr<webrtc::IceCandidateInterface> candidate) override { |
176 switch (candidate->sdp_mline_index()) { | 177 switch (candidate->sdp_mline_index()) { |
177 case kMediaContentIndex0: | 178 case kMediaContentIndex0: |
178 mline_0_candidates_.push_back(candidate->candidate()); | 179 mline_0_candidates_.push_back(candidate->candidate()); |
179 break; | 180 break; |
180 case kMediaContentIndex1: | 181 case kMediaContentIndex1: |
181 mline_1_candidates_.push_back(candidate->candidate()); | 182 mline_1_candidates_.push_back(candidate->candidate()); |
182 break; | 183 break; |
183 default: | 184 default: |
184 RTC_NOTREACHED(); | 185 RTC_NOTREACHED(); |
185 } | 186 } |
(...skipping 4156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4342 } | 4343 } |
4343 | 4344 |
4344 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test | 4345 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test |
4345 // currently fails because upon disconnection and reconnection OnIceComplete is | 4346 // currently fails because upon disconnection and reconnection OnIceComplete is |
4346 // called more than once without returning to IceGatheringGathering. | 4347 // called more than once without returning to IceGatheringGathering. |
4347 | 4348 |
4348 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests, | 4349 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests, |
4349 WebRtcSessionTest, | 4350 WebRtcSessionTest, |
4350 testing::Values(ALREADY_GENERATED, | 4351 testing::Values(ALREADY_GENERATED, |
4351 DTLS_IDENTITY_STORE)); | 4352 DTLS_IDENTITY_STORE)); |
OLD | NEW |