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

Side by Side Diff: webrtc/api/webrtcsession_unittest.cc

Issue 1648813004: Remove candidates when doing continual gathering (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Fix a Windows compiling error Created 4 years, 9 months 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 unified diff | Download patch
OLDNEW
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 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 break; 186 break;
187 default: 187 default:
188 ASSERT(false); 188 ASSERT(false);
189 } 189 }
190 190
191 // The ICE gathering state should always be Gathering when a candidate is 191 // The ICE gathering state should always be Gathering when a candidate is
192 // received (or possibly Completed in the case of the final candidate). 192 // received (or possibly Completed in the case of the final candidate).
193 EXPECT_NE(PeerConnectionInterface::kIceGatheringNew, ice_gathering_state_); 193 EXPECT_NE(PeerConnectionInterface::kIceGatheringNew, ice_gathering_state_);
194 } 194 }
195 195
196 // Some local candidates are removed.
197 void OnIceCandidatesRemoved(
198 const std::vector<webrtc::IceCandidateInterfaceRefPtr>& candidates) {}
199
196 bool oncandidatesready_; 200 bool oncandidatesready_;
197 std::vector<cricket::Candidate> mline_0_candidates_; 201 std::vector<cricket::Candidate> mline_0_candidates_;
198 std::vector<cricket::Candidate> mline_1_candidates_; 202 std::vector<cricket::Candidate> mline_1_candidates_;
199 PeerConnectionInterface::IceConnectionState ice_connection_state_; 203 PeerConnectionInterface::IceConnectionState ice_connection_state_;
200 PeerConnectionInterface::IceGatheringState ice_gathering_state_; 204 PeerConnectionInterface::IceGatheringState ice_gathering_state_;
201 }; 205 };
202 206
203 class WebRtcSessionForTest : public webrtc::WebRtcSession { 207 class WebRtcSessionForTest : public webrtc::WebRtcSession {
204 public: 208 public:
205 WebRtcSessionForTest(webrtc::MediaControllerInterface* media_controller, 209 WebRtcSessionForTest(webrtc::MediaControllerInterface* media_controller,
(...skipping 4049 matching lines...) Expand 10 before | Expand all | Expand 10 after
4255 } 4259 }
4256 4260
4257 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test 4261 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test
4258 // currently fails because upon disconnection and reconnection OnIceComplete is 4262 // currently fails because upon disconnection and reconnection OnIceComplete is
4259 // called more than once without returning to IceGatheringGathering. 4263 // called more than once without returning to IceGatheringGathering.
4260 4264
4261 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests, 4265 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests,
4262 WebRtcSessionTest, 4266 WebRtcSessionTest,
4263 testing::Values(ALREADY_GENERATED, 4267 testing::Values(ALREADY_GENERATED,
4264 DTLS_IDENTITY_STORE)); 4268 DTLS_IDENTITY_STORE));
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698