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 598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
609 EXPECT_EQ(PeerConnectionInterface::kStable, observer_.state_); | 609 EXPECT_EQ(PeerConnectionInterface::kStable, observer_.state_); |
610 } | 610 } |
611 | 611 |
612 void CreatePeerConnectionExpectFail(const std::string& uri) { | 612 void CreatePeerConnectionExpectFail(const std::string& uri) { |
613 PeerConnectionInterface::RTCConfiguration config; | 613 PeerConnectionInterface::RTCConfiguration config; |
614 PeerConnectionInterface::IceServer server; | 614 PeerConnectionInterface::IceServer server; |
615 server.uri = uri; | 615 server.uri = uri; |
616 config.servers.push_back(server); | 616 config.servers.push_back(server); |
617 | 617 |
618 scoped_refptr<PeerConnectionInterface> pc; | 618 scoped_refptr<PeerConnectionInterface> pc; |
619 pc = pc_factory_->CreatePeerConnection( | 619 pc = pc_factory_->CreatePeerConnection(config, nullptr, nullptr, nullptr, |
620 config, | 620 &observer_); |
621 nullptr, | |
622 nullptr, | |
623 std::unique_ptr<rtc::RTCCertificateGeneratorInterface>(), | |
624 &observer_); | |
625 EXPECT_EQ(nullptr, pc); | 621 EXPECT_EQ(nullptr, pc); |
626 } | 622 } |
627 | 623 |
628 void CreatePeerConnectionWithDifferentConfigurations() { | 624 void CreatePeerConnectionWithDifferentConfigurations() { |
629 CreatePeerConnectionWithIceServer(kStunAddressOnly, ""); | 625 CreatePeerConnectionWithIceServer(kStunAddressOnly, ""); |
630 EXPECT_EQ(1u, port_allocator_->stun_servers().size()); | 626 EXPECT_EQ(1u, port_allocator_->stun_servers().size()); |
631 EXPECT_EQ(0u, port_allocator_->turn_servers().size()); | 627 EXPECT_EQ(0u, port_allocator_->turn_servers().size()); |
632 EXPECT_EQ("address", port_allocator_->stun_servers().begin()->hostname()); | 628 EXPECT_EQ("address", port_allocator_->stun_servers().begin()->hostname()); |
633 EXPECT_EQ(kDefaultStunPort, | 629 EXPECT_EQ(kDefaultStunPort, |
634 port_allocator_->stun_servers().begin()->port()); | 630 port_allocator_->stun_servers().begin()->port()); |
(...skipping 2173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2808 FakeConstraints updated_answer_c; | 2804 FakeConstraints updated_answer_c; |
2809 answer_c.SetMandatoryReceiveAudio(false); | 2805 answer_c.SetMandatoryReceiveAudio(false); |
2810 answer_c.SetMandatoryReceiveVideo(false); | 2806 answer_c.SetMandatoryReceiveVideo(false); |
2811 | 2807 |
2812 cricket::MediaSessionOptions updated_answer_options; | 2808 cricket::MediaSessionOptions updated_answer_options; |
2813 EXPECT_TRUE( | 2809 EXPECT_TRUE( |
2814 ParseConstraintsForAnswer(&updated_answer_c, &updated_answer_options)); | 2810 ParseConstraintsForAnswer(&updated_answer_c, &updated_answer_options)); |
2815 EXPECT_TRUE(updated_answer_options.has_audio()); | 2811 EXPECT_TRUE(updated_answer_options.has_audio()); |
2816 EXPECT_TRUE(updated_answer_options.has_video()); | 2812 EXPECT_TRUE(updated_answer_options.has_video()); |
2817 } | 2813 } |
OLD | NEW |