OLD | NEW |
1 /* | 1 /* |
2 * libjingle | 2 * libjingle |
3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 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, |
11 * this list of conditions and the following disclaimer in the documentation | 11 * this list of conditions and the following disclaimer in the documentation |
12 * and/or other materials provided with the distribution. | 12 * and/or other materials provided with the distribution. |
13 * 3. The name of the author may not be used to endorse or promote products | 13 * 3. The name of the author may not be used to endorse or promote products |
14 * derived from this software without specific prior written permission. | 14 * derived from this software without specific prior written permission. |
15 * | 15 * |
16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED | 16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED |
17 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF | 17 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
18 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO | 18 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO |
19 * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | 19 * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, | 20 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
21 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; | 21 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; |
22 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, | 22 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, |
23 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR | 23 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR |
24 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF | 24 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF |
25 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 */ | 26 */ |
27 | 27 |
28 #include "talk/app/webrtc/audiotrack.h" | 28 #include "talk/app/webrtc/audiotrack.h" |
| 29 #include "talk/app/webrtc/dtlscertificate.h" |
29 #include "talk/app/webrtc/fakemetricsobserver.h" | 30 #include "talk/app/webrtc/fakemetricsobserver.h" |
30 #include "talk/app/webrtc/jsepicecandidate.h" | 31 #include "talk/app/webrtc/jsepicecandidate.h" |
31 #include "talk/app/webrtc/jsepsessiondescription.h" | 32 #include "talk/app/webrtc/jsepsessiondescription.h" |
32 #include "talk/app/webrtc/mediastreamsignaling.h" | 33 #include "talk/app/webrtc/mediastreamsignaling.h" |
33 #include "talk/app/webrtc/streamcollection.h" | 34 #include "talk/app/webrtc/streamcollection.h" |
34 #include "talk/app/webrtc/test/fakeconstraints.h" | 35 #include "talk/app/webrtc/test/fakeconstraints.h" |
35 #include "talk/app/webrtc/test/fakedtlsidentityservice.h" | 36 #include "talk/app/webrtc/test/fakedtlsidentityservice.h" |
36 #include "talk/app/webrtc/test/fakemediastreamsignaling.h" | 37 #include "talk/app/webrtc/test/fakemediastreamsignaling.h" |
37 #include "talk/app/webrtc/videotrack.h" | 38 #include "talk/app/webrtc/videotrack.h" |
38 #include "talk/app/webrtc/webrtcsession.h" | 39 #include "talk/app/webrtc/webrtcsession.h" |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
352 desc_factory_->set_add_legacy_streams(false); | 353 desc_factory_->set_add_legacy_streams(false); |
353 allocator_->set_step_delay(cricket::kMinimumStepDelay); | 354 allocator_->set_step_delay(cricket::kMinimumStepDelay); |
354 } | 355 } |
355 | 356 |
356 void AddInterface(const SocketAddress& addr) { | 357 void AddInterface(const SocketAddress& addr) { |
357 network_manager_.AddInterface(addr); | 358 network_manager_.AddInterface(addr); |
358 } | 359 } |
359 | 360 |
360 void Init( | 361 void Init( |
361 DTLSIdentityServiceInterface* identity_service, | 362 DTLSIdentityServiceInterface* identity_service, |
| 363 rtc::scoped_refptr<webrtc::DtlsCertificate> certificate, |
362 const PeerConnectionInterface::RTCConfiguration& rtc_configuration) { | 364 const PeerConnectionInterface::RTCConfiguration& rtc_configuration) { |
363 ASSERT_TRUE(session_.get() == NULL); | 365 ASSERT_TRUE(session_.get() == NULL); |
364 session_.reset(new WebRtcSessionForTest( | 366 session_.reset(new WebRtcSessionForTest( |
365 channel_manager_.get(), rtc::Thread::Current(), | 367 channel_manager_.get(), rtc::Thread::Current(), |
366 rtc::Thread::Current(), allocator_.get(), | 368 rtc::Thread::Current(), allocator_.get(), |
367 &observer_, | 369 &observer_, |
368 &mediastream_signaling_)); | 370 &mediastream_signaling_)); |
369 | 371 |
370 EXPECT_EQ(PeerConnectionInterface::kIceConnectionNew, | 372 EXPECT_EQ(PeerConnectionInterface::kIceConnectionNew, |
371 observer_.ice_connection_state_); | 373 observer_.ice_connection_state_); |
372 EXPECT_EQ(PeerConnectionInterface::kIceGatheringNew, | 374 EXPECT_EQ(PeerConnectionInterface::kIceGatheringNew, |
373 observer_.ice_gathering_state_); | 375 observer_.ice_gathering_state_); |
374 | 376 |
375 EXPECT_TRUE(session_->Initialize(options_, constraints_.get(), | 377 if (!certificate) { |
376 identity_service, rtc_configuration)); | 378 EXPECT_TRUE(session_->Initialize(options_, constraints_.get(), |
| 379 identity_service, rtc_configuration)); |
| 380 } else { |
| 381 EXPECT_TRUE(session_->Initialize(options_, constraints_.get(), |
| 382 certificate, rtc_configuration)); |
| 383 } |
377 session_->set_metrics_observer(metrics_observer_); | 384 session_->set_metrics_observer(metrics_observer_); |
378 } | 385 } |
379 | 386 |
380 void Init() { | 387 void Init() { |
381 PeerConnectionInterface::RTCConfiguration configuration; | 388 PeerConnectionInterface::RTCConfiguration configuration; |
382 Init(NULL, configuration); | 389 Init(nullptr, nullptr, configuration); |
383 } | 390 } |
384 | 391 |
385 void InitWithIceTransport( | 392 void InitWithIceTransport( |
386 PeerConnectionInterface::IceTransportsType ice_transport_type) { | 393 PeerConnectionInterface::IceTransportsType ice_transport_type) { |
387 PeerConnectionInterface::RTCConfiguration configuration; | 394 PeerConnectionInterface::RTCConfiguration configuration; |
388 configuration.type = ice_transport_type; | 395 configuration.type = ice_transport_type; |
389 Init(NULL, configuration); | 396 Init(nullptr, nullptr, configuration); |
390 } | 397 } |
391 | 398 |
392 void InitWithBundlePolicy( | 399 void InitWithBundlePolicy( |
393 PeerConnectionInterface::BundlePolicy bundle_policy) { | 400 PeerConnectionInterface::BundlePolicy bundle_policy) { |
394 PeerConnectionInterface::RTCConfiguration configuration; | 401 PeerConnectionInterface::RTCConfiguration configuration; |
395 configuration.bundle_policy = bundle_policy; | 402 configuration.bundle_policy = bundle_policy; |
396 Init(NULL, configuration); | 403 Init(nullptr, nullptr, configuration); |
397 } | 404 } |
398 | 405 |
399 void InitWithRtcpMuxPolicy( | 406 void InitWithRtcpMuxPolicy( |
400 PeerConnectionInterface::RtcpMuxPolicy rtcp_mux_policy) { | 407 PeerConnectionInterface::RtcpMuxPolicy rtcp_mux_policy) { |
401 PeerConnectionInterface::RTCConfiguration configuration; | 408 PeerConnectionInterface::RTCConfiguration configuration; |
402 configuration.rtcp_mux_policy = rtcp_mux_policy; | 409 configuration.rtcp_mux_policy = rtcp_mux_policy; |
403 Init(NULL, configuration); | 410 Init(nullptr, nullptr, configuration); |
404 } | 411 } |
405 | 412 |
406 void InitWithDtls(bool identity_request_should_fail = false) { | 413 void InitWithDtls(bool identity_request_should_fail = false) { |
407 FakeIdentityService* identity_service = new FakeIdentityService(); | 414 FakeIdentityService* identity_service = new FakeIdentityService(); |
408 identity_service->set_should_fail(identity_request_should_fail); | 415 identity_service->set_should_fail(identity_request_should_fail); |
409 PeerConnectionInterface::RTCConfiguration configuration; | 416 PeerConnectionInterface::RTCConfiguration configuration; |
410 Init(identity_service, configuration); | 417 Init(identity_service, nullptr, configuration); |
411 } | 418 } |
412 | 419 |
413 void InitWithDtmfCodec() { | 420 void InitWithDtmfCodec() { |
414 // Add kTelephoneEventCodec for dtmf test. | 421 // Add kTelephoneEventCodec for dtmf test. |
415 const cricket::AudioCodec kTelephoneEventCodec( | 422 const cricket::AudioCodec kTelephoneEventCodec( |
416 106, "telephone-event", 8000, 0, 1, 0); | 423 106, "telephone-event", 8000, 0, 1, 0); |
417 std::vector<cricket::AudioCodec> codecs; | 424 std::vector<cricket::AudioCodec> codecs; |
418 codecs.push_back(kTelephoneEventCodec); | 425 codecs.push_back(kTelephoneEventCodec); |
419 media_engine_->SetAudioCodecs(codecs); | 426 media_engine_->SetAudioCodecs(codecs); |
420 desc_factory_->set_audio_codecs(codecs); | 427 desc_factory_->set_audio_codecs(codecs); |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
531 EXPECT_EQ(std::string(cricket::kMediaProtocolAvpf), | 538 EXPECT_EQ(std::string(cricket::kMediaProtocolAvpf), |
532 video_content->protocol()); | 539 video_content->protocol()); |
533 } | 540 } |
534 } | 541 } |
535 | 542 |
536 // Set the internal fake description factories to do DTLS-SRTP. | 543 // Set the internal fake description factories to do DTLS-SRTP. |
537 void SetFactoryDtlsSrtp() { | 544 void SetFactoryDtlsSrtp() { |
538 desc_factory_->set_secure(cricket::SEC_DISABLED); | 545 desc_factory_->set_secure(cricket::SEC_DISABLED); |
539 std::string identity_name = "WebRTC" + | 546 std::string identity_name = "WebRTC" + |
540 rtc::ToString(rtc::CreateRandomId()); | 547 rtc::ToString(rtc::CreateRandomId()); |
541 identity_.reset(rtc::SSLIdentity::Generate(identity_name)); | 548 certificate_ = webrtc::DtlsCertificate::Create( |
542 tdesc_factory_->set_identity(identity_.get()); | 549 rtc::scoped_ptr<rtc::SSLIdentity>( |
| 550 rtc::SSLIdentity::Generate(identity_name)).Pass()); |
| 551 tdesc_factory_->set_certificate(certificate_); |
543 tdesc_factory_->set_secure(cricket::SEC_REQUIRED); | 552 tdesc_factory_->set_secure(cricket::SEC_REQUIRED); |
544 } | 553 } |
545 | 554 |
546 void VerifyFingerprintStatus(const cricket::SessionDescription* sdp, | 555 void VerifyFingerprintStatus(const cricket::SessionDescription* sdp, |
547 bool expected) { | 556 bool expected) { |
548 const TransportInfo* audio = sdp->GetTransportInfoByName("audio"); | 557 const TransportInfo* audio = sdp->GetTransportInfoByName("audio"); |
549 ASSERT_TRUE(audio != NULL); | 558 ASSERT_TRUE(audio != NULL); |
550 ASSERT_EQ(expected, audio->description.identity_fingerprint.get() != NULL); | 559 ASSERT_EQ(expected, audio->description.identity_fingerprint.get() != NULL); |
551 const TransportInfo* video = sdp->GetTransportInfoByName("video"); | 560 const TransportInfo* video = sdp->GetTransportInfoByName("video"); |
552 ASSERT_TRUE(video != NULL); | 561 ASSERT_TRUE(video != NULL); |
(...skipping 677 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1230 allocator_->set_step_delay(cricket::kMinimumStepDelay); | 1239 allocator_->set_step_delay(cricket::kMinimumStepDelay); |
1231 allocator_->set_flags(cricket::PORTALLOCATOR_DISABLE_TCP | | 1240 allocator_->set_flags(cricket::PORTALLOCATOR_DISABLE_TCP | |
1232 cricket::PORTALLOCATOR_ENABLE_SHARED_UFRAG); | 1241 cricket::PORTALLOCATOR_ENABLE_SHARED_UFRAG); |
1233 } | 1242 } |
1234 | 1243 |
1235 cricket::FakeMediaEngine* media_engine_; | 1244 cricket::FakeMediaEngine* media_engine_; |
1236 cricket::FakeDataEngine* data_engine_; | 1245 cricket::FakeDataEngine* data_engine_; |
1237 cricket::FakeDeviceManager* device_manager_; | 1246 cricket::FakeDeviceManager* device_manager_; |
1238 rtc::scoped_ptr<cricket::ChannelManager> channel_manager_; | 1247 rtc::scoped_ptr<cricket::ChannelManager> channel_manager_; |
1239 rtc::scoped_ptr<cricket::TransportDescriptionFactory> tdesc_factory_; | 1248 rtc::scoped_ptr<cricket::TransportDescriptionFactory> tdesc_factory_; |
1240 rtc::scoped_ptr<rtc::SSLIdentity> identity_; | 1249 rtc::scoped_refptr<webrtc::DtlsCertificate> certificate_; |
1241 rtc::scoped_ptr<cricket::MediaSessionDescriptionFactory> desc_factory_; | 1250 rtc::scoped_ptr<cricket::MediaSessionDescriptionFactory> desc_factory_; |
1242 rtc::scoped_ptr<rtc::PhysicalSocketServer> pss_; | 1251 rtc::scoped_ptr<rtc::PhysicalSocketServer> pss_; |
1243 rtc::scoped_ptr<rtc::VirtualSocketServer> vss_; | 1252 rtc::scoped_ptr<rtc::VirtualSocketServer> vss_; |
1244 rtc::scoped_ptr<rtc::FirewallSocketServer> fss_; | 1253 rtc::scoped_ptr<rtc::FirewallSocketServer> fss_; |
1245 rtc::SocketServerScope ss_scope_; | 1254 rtc::SocketServerScope ss_scope_; |
1246 rtc::SocketAddress stun_socket_addr_; | 1255 rtc::SocketAddress stun_socket_addr_; |
1247 rtc::scoped_ptr<cricket::TestStunServer> stun_server_; | 1256 rtc::scoped_ptr<cricket::TestStunServer> stun_server_; |
1248 cricket::TestTurnServer turn_server_; | 1257 cricket::TestTurnServer turn_server_; |
1249 rtc::FakeNetworkManager network_manager_; | 1258 rtc::FakeNetworkManager network_manager_; |
1250 rtc::scoped_ptr<cricket::BasicPortAllocator> allocator_; | 1259 rtc::scoped_ptr<cricket::BasicPortAllocator> allocator_; |
(...skipping 2334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3585 | 3594 |
3586 ASSERT_EQ(1UL, ch->recv_codecs().size()); | 3595 ASSERT_EQ(1UL, ch->recv_codecs().size()); |
3587 EXPECT_EQ(cricket::kGoogleSctpDataCodecId, ch->recv_codecs()[0].id); | 3596 EXPECT_EQ(cricket::kGoogleSctpDataCodecId, ch->recv_codecs()[0].id); |
3588 EXPECT_EQ(0, strcmp(cricket::kGoogleSctpDataCodecName, | 3597 EXPECT_EQ(0, strcmp(cricket::kGoogleSctpDataCodecName, |
3589 ch->recv_codecs()[0].name.c_str())); | 3598 ch->recv_codecs()[0].name.c_str())); |
3590 EXPECT_TRUE(ch->recv_codecs()[0].GetParam(cricket::kCodecParamPort, | 3599 EXPECT_TRUE(ch->recv_codecs()[0].GetParam(cricket::kCodecParamPort, |
3591 &portnum)); | 3600 &portnum)); |
3592 EXPECT_EQ(new_recv_port, portnum); | 3601 EXPECT_EQ(new_recv_port, portnum); |
3593 } | 3602 } |
3594 | 3603 |
| 3604 // Verifies that if a certificate is provided it is the one that will be used. |
| 3605 TEST_F(WebRtcSessionTest, TestUsesProvidedCertificate) { |
| 3606 rtc::scoped_refptr<webrtc::DtlsCertificate> certificate = |
| 3607 FakeIdentityService::GenerateCertificate(); |
| 3608 |
| 3609 PeerConnectionInterface::RTCConfiguration configuration; |
| 3610 Init(nullptr, certificate, configuration); |
| 3611 EXPECT_TRUE_WAIT(!session_->waiting_for_certificate(), 1000); |
| 3612 |
| 3613 EXPECT_EQ(session_->get_certificate(), certificate); |
| 3614 } |
| 3615 |
3595 // Verifies that CreateOffer succeeds when CreateOffer is called before async | 3616 // Verifies that CreateOffer succeeds when CreateOffer is called before async |
3596 // identity generation is finished. | 3617 // identity generation is finished. |
3597 TEST_F(WebRtcSessionTest, TestCreateOfferBeforeIdentityRequestReturnSuccess) { | 3618 TEST_F(WebRtcSessionTest, TestCreateOfferBeforeIdentityRequestReturnSuccess) { |
3598 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); | 3619 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); |
3599 InitWithDtls(); | 3620 InitWithDtls(); |
3600 | 3621 |
3601 EXPECT_TRUE(session_->waiting_for_identity()); | 3622 EXPECT_TRUE(session_->waiting_for_certificate()); |
3602 mediastream_signaling_.SendAudioVideoStream1(); | 3623 mediastream_signaling_.SendAudioVideoStream1(); |
3603 rtc::scoped_ptr<SessionDescriptionInterface> offer(CreateOffer()); | 3624 rtc::scoped_ptr<SessionDescriptionInterface> offer(CreateOffer()); |
3604 | 3625 |
3605 EXPECT_TRUE(offer != NULL); | 3626 EXPECT_TRUE(offer != NULL); |
3606 VerifyNoCryptoParams(offer->description(), true); | 3627 VerifyNoCryptoParams(offer->description(), true); |
3607 VerifyFingerprintStatus(offer->description(), true); | 3628 VerifyFingerprintStatus(offer->description(), true); |
3608 } | 3629 } |
3609 | 3630 |
3610 // Verifies that CreateAnswer succeeds when CreateOffer is called before async | 3631 // Verifies that CreateAnswer succeeds when CreateOffer is called before async |
3611 // identity generation is finished. | 3632 // identity generation is finished. |
(...skipping 14 matching lines...) Expand all Loading... |
3626 VerifyNoCryptoParams(answer->description(), true); | 3647 VerifyNoCryptoParams(answer->description(), true); |
3627 VerifyFingerprintStatus(answer->description(), true); | 3648 VerifyFingerprintStatus(answer->description(), true); |
3628 } | 3649 } |
3629 | 3650 |
3630 // Verifies that CreateOffer succeeds when CreateOffer is called after async | 3651 // Verifies that CreateOffer succeeds when CreateOffer is called after async |
3631 // identity generation is finished. | 3652 // identity generation is finished. |
3632 TEST_F(WebRtcSessionTest, TestCreateOfferAfterIdentityRequestReturnSuccess) { | 3653 TEST_F(WebRtcSessionTest, TestCreateOfferAfterIdentityRequestReturnSuccess) { |
3633 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); | 3654 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); |
3634 InitWithDtls(); | 3655 InitWithDtls(); |
3635 | 3656 |
3636 EXPECT_TRUE_WAIT(!session_->waiting_for_identity(), 1000); | 3657 EXPECT_TRUE_WAIT(!session_->waiting_for_certificate(), 1000); |
3637 | 3658 |
3638 rtc::scoped_ptr<SessionDescriptionInterface> offer(CreateOffer()); | 3659 rtc::scoped_ptr<SessionDescriptionInterface> offer(CreateOffer()); |
3639 EXPECT_TRUE(offer != NULL); | 3660 EXPECT_TRUE(offer != NULL); |
3640 } | 3661 } |
3641 | 3662 |
3642 // Verifies that CreateOffer fails when CreateOffer is called after async | 3663 // Verifies that CreateOffer fails when CreateOffer is called after async |
3643 // identity generation fails. | 3664 // identity generation fails. |
3644 TEST_F(WebRtcSessionTest, TestCreateOfferAfterIdentityRequestReturnFailure) { | 3665 TEST_F(WebRtcSessionTest, TestCreateOfferAfterIdentityRequestReturnFailure) { |
3645 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); | 3666 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); |
3646 InitWithDtls(true); | 3667 InitWithDtls(true); |
3647 | 3668 |
3648 EXPECT_TRUE_WAIT(!session_->waiting_for_identity(), 1000); | 3669 EXPECT_TRUE_WAIT(!session_->waiting_for_certificate(), 1000); |
3649 | 3670 |
3650 rtc::scoped_ptr<SessionDescriptionInterface> offer(CreateOffer()); | 3671 rtc::scoped_ptr<SessionDescriptionInterface> offer(CreateOffer()); |
3651 EXPECT_TRUE(offer == NULL); | 3672 EXPECT_TRUE(offer == NULL); |
3652 } | 3673 } |
3653 | 3674 |
3654 // Verifies that CreateOffer succeeds when Multiple CreateOffer calls are made | 3675 // Verifies that CreateOffer succeeds when Multiple CreateOffer calls are made |
3655 // before async identity generation is finished. | 3676 // before async identity generation is finished. |
3656 TEST_F(WebRtcSessionTest, | 3677 TEST_F(WebRtcSessionTest, |
3657 TestMultipleCreateOfferBeforeIdentityRequestReturnSuccess) { | 3678 TestMultipleCreateOfferBeforeIdentityRequestReturnSuccess) { |
3658 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); | 3679 MAYBE_SKIP_TEST(rtc::SSLStreamAdapter::HaveDtlsSrtp); |
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3941 // terminated. The offer creation may or may not have succeeded, but we | 3962 // terminated. The offer creation may or may not have succeeded, but we |
3942 // must have received a notification which, so the only invalid state | 3963 // must have received a notification which, so the only invalid state |
3943 // is kInit. | 3964 // is kInit. |
3944 EXPECT_NE(WebRtcSessionCreateSDPObserverForTest::kInit, o->state()); | 3965 EXPECT_NE(WebRtcSessionCreateSDPObserverForTest::kInit, o->state()); |
3945 } | 3966 } |
3946 } | 3967 } |
3947 | 3968 |
3948 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test | 3969 // TODO(bemasc): Add a TestIceStatesBundle with BUNDLE enabled. That test |
3949 // currently fails because upon disconnection and reconnection OnIceComplete is | 3970 // currently fails because upon disconnection and reconnection OnIceComplete is |
3950 // called more than once without returning to IceGatheringGathering. | 3971 // called more than once without returning to IceGatheringGathering. |
OLD | NEW |