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

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

Issue 3012953002: Created the DtlsSrtpTransport.
Patch Set: Initial review. Created 3 years, 3 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 1205 matching lines...) Expand 10 before | Expand all | Expand 10 after
1216 const SessionDescriptionInterface* current_desc) { 1216 const SessionDescriptionInterface* current_desc) {
1217 return CreateRemoteOfferWithVersion(options, cricket::SEC_ENABLED, 1217 return CreateRemoteOfferWithVersion(options, cricket::SEC_ENABLED,
1218 kSessionVersion, current_desc); 1218 kSessionVersion, current_desc);
1219 } 1219 }
1220 1220
1221 JsepSessionDescription* CreateRemoteOfferWithSctpPort( 1221 JsepSessionDescription* CreateRemoteOfferWithSctpPort(
1222 const char* sctp_stream_name, int new_port, 1222 const char* sctp_stream_name, int new_port,
1223 cricket::MediaSessionOptions options) { 1223 cricket::MediaSessionOptions options) {
1224 options.data_channel_type = cricket::DCT_SCTP; 1224 options.data_channel_type = cricket::DCT_SCTP;
1225 GetOptionsForRemoteOffer(&options); 1225 GetOptionsForRemoteOffer(&options);
1226 return ChangeSDPSctpPort(new_port, CreateRemoteOffer(options)); 1226 return ChangeSDPSctpPort(new_port,
1227 CreateRemoteOffer(options, cricket::SEC_DISABLED));
1227 } 1228 }
1228 1229
1229 // Takes ownership of offer_basis (and deletes it). 1230 // Takes ownership of offer_basis (and deletes it).
1230 JsepSessionDescription* ChangeSDPSctpPort( 1231 JsepSessionDescription* ChangeSDPSctpPort(
1231 int new_port, webrtc::SessionDescriptionInterface *offer_basis) { 1232 int new_port, webrtc::SessionDescriptionInterface *offer_basis) {
1232 // Stringify the input SDP, swap the 5000 for 'new_port' and create a new 1233 // Stringify the input SDP, swap the 5000 for 'new_port' and create a new
1233 // SessionDescription from the mutated string. 1234 // SessionDescription from the mutated string.
1234 const char* default_port_str = "5000"; 1235 const char* default_port_str = "5000";
1235 char new_port_str[16]; 1236 char new_port_str[16];
1236 rtc::sprintfn(new_port_str, sizeof(new_port_str), "%d", new_port); 1237 rtc::sprintfn(new_port_str, sizeof(new_port_str), "%d", new_port);
(...skipping 3329 matching lines...) Expand 10 before | Expand all | Expand 10 after
4566 } 4567 }
4567 4568
4568 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test 4569 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test
4569 // currently fails because upon disconnection and reconnection OnIceComplete is 4570 // currently fails because upon disconnection and reconnection OnIceComplete is
4570 // called more than once without returning to IceGatheringGathering. 4571 // called more than once without returning to IceGatheringGathering.
4571 4572
4572 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests, 4573 INSTANTIATE_TEST_CASE_P(WebRtcSessionTests,
4573 WebRtcSessionTest, 4574 WebRtcSessionTest,
4574 testing::Values(ALREADY_GENERATED, 4575 testing::Values(ALREADY_GENERATED,
4575 DTLS_IDENTITY_STORE)); 4576 DTLS_IDENTITY_STORE));
OLDNEW
« webrtc/pc/peerconnectioninterface_unittest.cc ('K') | « webrtc/pc/srtptransport_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698