| 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 3021 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3032 | 3032 |
| 3033 EXPECT_EQ(session_->voice_rtp_transport_channel(), | 3033 EXPECT_EQ(session_->voice_rtp_transport_channel(), |
| 3034 session_->video_rtp_transport_channel()); | 3034 session_->video_rtp_transport_channel()); |
| 3035 | 3035 |
| 3036 cricket::BaseChannel* voice_channel = session_->voice_channel(); | 3036 cricket::BaseChannel* voice_channel = session_->voice_channel(); |
| 3037 ASSERT(voice_channel != NULL); | 3037 ASSERT(voice_channel != NULL); |
| 3038 | 3038 |
| 3039 // Checks if one of the transport channels contains a connection using a given | 3039 // Checks if one of the transport channels contains a connection using a given |
| 3040 // port. | 3040 // port. |
| 3041 auto connection_with_remote_port = [this, voice_channel](int port) { | 3041 auto connection_with_remote_port = [this, voice_channel](int port) { |
| 3042 SessionStats stats; | 3042 std::unique_ptr<webrtc::SessionStats> stats = session_->GetStats_s(); |
| 3043 session_->GetChannelTransportStats(voice_channel, &stats); | 3043 for (auto& kv : stats->transport_stats) { |
| 3044 for (auto& kv : stats.transport_stats) { | |
| 3045 for (auto& chan_stat : kv.second.channel_stats) { | 3044 for (auto& chan_stat : kv.second.channel_stats) { |
| 3046 for (auto& conn_info : chan_stat.connection_infos) { | 3045 for (auto& conn_info : chan_stat.connection_infos) { |
| 3047 if (conn_info.remote_candidate.address().port() == port) { | 3046 if (conn_info.remote_candidate.address().port() == port) { |
| 3048 return true; | 3047 return true; |
| 3049 } | 3048 } |
| 3050 } | 3049 } |
| 3051 } | 3050 } |
| 3052 } | 3051 } |
| 3053 return false; | 3052 return false; |
| 3054 }; | 3053 }; |
| (...skipping 1307 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4362 } | 4361 } |
| 4363 | 4362 |
| 4364 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test | 4363 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test |
| 4365 // currently fails because upon disconnection and reconnection OnIceComplete is | 4364 // currently fails because upon disconnection and reconnection OnIceComplete is |
| 4366 // called more than once without returning to IceGatheringGathering. | 4365 // called more than once without returning to IceGatheringGathering. |
| 4367 | 4366 |
| 4368 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests, | 4367 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests, |
| 4369 WebRtcSessionTest, | 4368 WebRtcSessionTest, |
| 4370 testing::Values(ALREADY_GENERATED, | 4369 testing::Values(ALREADY_GENERATED, |
| 4371 DTLS_IDENTITY_STORE)); | 4370 DTLS_IDENTITY_STORE)); |
| OLD | NEW |