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

Side by Side Diff: talk/app/webrtc/peerconnection_unittest.cc

Issue 1176383004: DtlsIdentityStore[Interface/Impl] updated, DtlsIdentityService to be removed (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Merge w master AFTER the landing of 1268363002. "CreatePC(service,store)" using store instead of service. Created 5 years, 4 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
« no previous file with comments | « talk/app/webrtc/peerconnection.cc ('k') | talk/app/webrtc/peerconnectionfactory.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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,
(...skipping 23 matching lines...) Expand all
34 34
35 #include "talk/app/webrtc/dtmfsender.h" 35 #include "talk/app/webrtc/dtmfsender.h"
36 #include "talk/app/webrtc/fakemetricsobserver.h" 36 #include "talk/app/webrtc/fakemetricsobserver.h"
37 #include "talk/app/webrtc/fakeportallocatorfactory.h" 37 #include "talk/app/webrtc/fakeportallocatorfactory.h"
38 #include "talk/app/webrtc/localaudiosource.h" 38 #include "talk/app/webrtc/localaudiosource.h"
39 #include "talk/app/webrtc/mediastreaminterface.h" 39 #include "talk/app/webrtc/mediastreaminterface.h"
40 #include "talk/app/webrtc/peerconnectionfactory.h" 40 #include "talk/app/webrtc/peerconnectionfactory.h"
41 #include "talk/app/webrtc/peerconnectioninterface.h" 41 #include "talk/app/webrtc/peerconnectioninterface.h"
42 #include "talk/app/webrtc/test/fakeaudiocapturemodule.h" 42 #include "talk/app/webrtc/test/fakeaudiocapturemodule.h"
43 #include "talk/app/webrtc/test/fakeconstraints.h" 43 #include "talk/app/webrtc/test/fakeconstraints.h"
44 #include "talk/app/webrtc/test/fakedtlsidentityservice.h" 44 #include "talk/app/webrtc/test/fakedtlsidentitystore.h"
45 #include "talk/app/webrtc/test/fakeperiodicvideocapturer.h" 45 #include "talk/app/webrtc/test/fakeperiodicvideocapturer.h"
46 #include "talk/app/webrtc/test/fakevideotrackrenderer.h" 46 #include "talk/app/webrtc/test/fakevideotrackrenderer.h"
47 #include "talk/app/webrtc/test/mockpeerconnectionobservers.h" 47 #include "talk/app/webrtc/test/mockpeerconnectionobservers.h"
48 #include "talk/app/webrtc/videosourceinterface.h" 48 #include "talk/app/webrtc/videosourceinterface.h"
49 #include "talk/media/webrtc/fakewebrtcvideoengine.h" 49 #include "talk/media/webrtc/fakewebrtcvideoengine.h"
50 #include "talk/session/media/mediasession.h" 50 #include "talk/session/media/mediasession.h"
51 #include "webrtc/base/gunit.h" 51 #include "webrtc/base/gunit.h"
52 #include "webrtc/base/physicalsocketserver.h" 52 #include "webrtc/base/physicalsocketserver.h"
53 #include "webrtc/base/scoped_ptr.h" 53 #include "webrtc/base/scoped_ptr.h"
54 #include "webrtc/base/ssladapter.h" 54 #include "webrtc/base/ssladapter.h"
(...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after
773 } 773 }
774 774
775 protected: 775 protected:
776 explicit JsepTestClient(const std::string& id) 776 explicit JsepTestClient(const std::string& id)
777 : PeerConnectionTestClientBase<JsepMessageReceiver>(id), 777 : PeerConnectionTestClientBase<JsepMessageReceiver>(id),
778 remove_msid_(false), 778 remove_msid_(false),
779 remove_bundle_(false), 779 remove_bundle_(false),
780 remove_sdes_(false) { 780 remove_sdes_(false) {
781 } 781 }
782 782
783 virtual rtc::scoped_refptr<webrtc::PeerConnectionInterface> 783 rtc::scoped_refptr<webrtc::PeerConnectionInterface>
784 CreatePeerConnection(webrtc::PortAllocatorFactoryInterface* factory, 784 CreatePeerConnection(
785 const MediaConstraintsInterface* constraints) { 785 webrtc::PortAllocatorFactoryInterface* factory,
786 const MediaConstraintsInterface* constraints) override {
786 // CreatePeerConnection with IceServers. 787 // CreatePeerConnection with IceServers.
787 webrtc::PeerConnectionInterface::IceServers ice_servers; 788 webrtc::PeerConnectionInterface::IceServers ice_servers;
788 webrtc::PeerConnectionInterface::IceServer ice_server; 789 webrtc::PeerConnectionInterface::IceServer ice_server;
789 ice_server.uri = "stun:stun.l.google.com:19302"; 790 ice_server.uri = "stun:stun.l.google.com:19302";
790 ice_servers.push_back(ice_server); 791 ice_servers.push_back(ice_server);
791 792
792 FakeIdentityService* dtls_service = 793 rtc::scoped_ptr<webrtc::DtlsIdentityStoreInterface> dtls_identity_store(
793 rtc::SSLStreamAdapter::HaveDtlsSrtp() ? 794 rtc::SSLStreamAdapter::HaveDtlsSrtp() ? new FakeDtlsIdentityStore()
794 new FakeIdentityService() : NULL; 795 : nullptr);
795 return peer_connection_factory()->CreatePeerConnection( 796 return peer_connection_factory()->CreatePeerConnection(
796 ice_servers, constraints, factory, dtls_service, this); 797 ice_servers, constraints, factory, dtls_identity_store.Pass(), this);
797 } 798 }
798 799
799 void HandleIncomingOffer(const std::string& msg) { 800 void HandleIncomingOffer(const std::string& msg) {
800 LOG(INFO) << id() << "HandleIncomingOffer "; 801 LOG(INFO) << id() << "HandleIncomingOffer ";
801 if (NumberOfLocalMediaStreams() == 0) { 802 if (NumberOfLocalMediaStreams() == 0) {
802 // If we are not sending any streams ourselves it is time to add some. 803 // If we are not sending any streams ourselves it is time to add some.
803 AddMediaStream(true, true); 804 AddMediaStream(true, true);
804 } 805 }
805 rtc::scoped_ptr<SessionDescriptionInterface> desc( 806 rtc::scoped_ptr<SessionDescriptionInterface> desc(
806 webrtc::CreateSessionDescription("offer", msg, NULL)); 807 webrtc::CreateSessionDescription("offer", msg, NULL));
(...skipping 813 matching lines...) Expand 10 before | Expand all | Expand 10 after
1620 // TODO(holmer): Disabled due to sometimes crashing on buildbots. 1621 // TODO(holmer): Disabled due to sometimes crashing on buildbots.
1621 // See issue webrtc/2378. 1622 // See issue webrtc/2378.
1622 TEST_F(JsepPeerConnectionP2PTestClient, 1623 TEST_F(JsepPeerConnectionP2PTestClient,
1623 DISABLED_LocalP2PTestWithVideoDecoderFactory) { 1624 DISABLED_LocalP2PTestWithVideoDecoderFactory) {
1624 ASSERT_TRUE(CreateTestClients()); 1625 ASSERT_TRUE(CreateTestClients());
1625 EnableVideoDecoderFactory(); 1626 EnableVideoDecoderFactory();
1626 LocalP2PTest(); 1627 LocalP2PTest();
1627 } 1628 }
1628 1629
1629 #endif // if !defined(THREAD_SANITIZER) 1630 #endif // if !defined(THREAD_SANITIZER)
OLDNEW
« no previous file with comments | « talk/app/webrtc/peerconnection.cc ('k') | talk/app/webrtc/peerconnectionfactory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698