| OLD | NEW |
| 1 /* | 1 /* |
| 2 * libjingle | 2 * libjingle |
| 3 * Copyright 2004 Google Inc. | 3 * Copyright 2004 Google Inc. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are met: | 6 * modification, are permitted provided that the following conditions are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright notice, | 8 * 1. Redistributions of source code must retain the above copyright notice, |
| 9 * this list of conditions and the following disclaimer. | 9 * this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright notice, | 10 * 2. Redistributions in binary form must reproduce the above copyright notice, |
| (...skipping 262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 273 const std::string current_video_ufrag = "current_video_ufrag"; | 273 const std::string current_video_ufrag = "current_video_ufrag"; |
| 274 const std::string current_video_pwd = "current_video_pwd"; | 274 const std::string current_video_pwd = "current_video_pwd"; |
| 275 const std::string current_data_ufrag = "current_data_ufrag"; | 275 const std::string current_data_ufrag = "current_data_ufrag"; |
| 276 const std::string current_data_pwd = "current_data_pwd"; | 276 const std::string current_data_pwd = "current_data_pwd"; |
| 277 rtc::scoped_ptr<SessionDescription> current_desc; | 277 rtc::scoped_ptr<SessionDescription> current_desc; |
| 278 rtc::scoped_ptr<SessionDescription> desc; | 278 rtc::scoped_ptr<SessionDescription> desc; |
| 279 if (has_current_desc) { | 279 if (has_current_desc) { |
| 280 current_desc.reset(new SessionDescription()); | 280 current_desc.reset(new SessionDescription()); |
| 281 EXPECT_TRUE(current_desc->AddTransportInfo( | 281 EXPECT_TRUE(current_desc->AddTransportInfo( |
| 282 TransportInfo("audio", | 282 TransportInfo("audio", |
| 283 TransportDescription("", | 283 TransportDescription(current_audio_ufrag, |
| 284 current_audio_ufrag, | |
| 285 current_audio_pwd)))); | 284 current_audio_pwd)))); |
| 286 EXPECT_TRUE(current_desc->AddTransportInfo( | 285 EXPECT_TRUE(current_desc->AddTransportInfo( |
| 287 TransportInfo("video", | 286 TransportInfo("video", |
| 288 TransportDescription("", | 287 TransportDescription(current_video_ufrag, |
| 289 current_video_ufrag, | |
| 290 current_video_pwd)))); | 288 current_video_pwd)))); |
| 291 EXPECT_TRUE(current_desc->AddTransportInfo( | 289 EXPECT_TRUE(current_desc->AddTransportInfo( |
| 292 TransportInfo("data", | 290 TransportInfo("data", |
| 293 TransportDescription("", | 291 TransportDescription(current_data_ufrag, |
| 294 current_data_ufrag, | |
| 295 current_data_pwd)))); | 292 current_data_pwd)))); |
| 296 } | 293 } |
| 297 if (offer) { | 294 if (offer) { |
| 298 desc.reset(f1_.CreateOffer(options, current_desc.get())); | 295 desc.reset(f1_.CreateOffer(options, current_desc.get())); |
| 299 } else { | 296 } else { |
| 300 rtc::scoped_ptr<SessionDescription> offer; | 297 rtc::scoped_ptr<SessionDescription> offer; |
| 301 offer.reset(f1_.CreateOffer(options, NULL)); | 298 offer.reset(f1_.CreateOffer(options, NULL)); |
| 302 desc.reset(f1_.CreateAnswer(offer.get(), options, current_desc.get())); | 299 desc.reset(f1_.CreateAnswer(offer.get(), options, current_desc.get())); |
| 303 } | 300 } |
| 304 ASSERT_TRUE(desc.get() != NULL); | 301 ASSERT_TRUE(desc.get() != NULL); |
| (...skipping 1951 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2256 offer.reset(f1_.CreateOffer(options, NULL)); | 2253 offer.reset(f1_.CreateOffer(options, NULL)); |
| 2257 ASSERT_TRUE(offer.get() != NULL); | 2254 ASSERT_TRUE(offer.get() != NULL); |
| 2258 audio_content = offer->GetContentByName("audio"); | 2255 audio_content = offer->GetContentByName("audio"); |
| 2259 EXPECT_TRUE(VerifyNoCNCodecs(audio_content)); | 2256 EXPECT_TRUE(VerifyNoCNCodecs(audio_content)); |
| 2260 rtc::scoped_ptr<SessionDescription> answer( | 2257 rtc::scoped_ptr<SessionDescription> answer( |
| 2261 f1_.CreateAnswer(offer.get(), options, NULL)); | 2258 f1_.CreateAnswer(offer.get(), options, NULL)); |
| 2262 ASSERT_TRUE(answer.get() != NULL); | 2259 ASSERT_TRUE(answer.get() != NULL); |
| 2263 audio_content = answer->GetContentByName("audio"); | 2260 audio_content = answer->GetContentByName("audio"); |
| 2264 EXPECT_TRUE(VerifyNoCNCodecs(audio_content)); | 2261 EXPECT_TRUE(VerifyNoCNCodecs(audio_content)); |
| 2265 } | 2262 } |
| OLD | NEW |