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

Unified Diff: webrtc/test/call_test.h

Issue 2794243002: Making FakeNetworkPipe demux audio and video packets. (Closed)
Patch Set: fixing android Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/test/call_test.h
diff --git a/webrtc/test/call_test.h b/webrtc/test/call_test.h
index c9d7f32b579bf2f6e6c81eeead78845c72a85550..b9523f59388eee644207445167aa9357fb3913e7 100644
--- a/webrtc/test/call_test.h
+++ b/webrtc/test/call_test.h
@@ -57,25 +57,9 @@ class CallTest : public ::testing::Test {
static const uint32_t kReceiverLocalVideoSsrc;
static const uint32_t kReceiverLocalAudioSsrc;
static const int kNackRtpHistoryMs;
+ static const std::map<uint8_t, MediaType> payload_type_map_;
protected:
- // Needed for tests sending both audio and video on the same
- // FakeNetworkPipe. We then need to set correct MediaType based on
- // packet payload type, before passing the packet on to Call.
- class PayloadDemuxer : public PacketReceiver {
- public:
- PayloadDemuxer() = default;
-
- void SetReceiver(PacketReceiver* receiver);
- DeliveryStatus DeliverPacket(MediaType media_type,
- const uint8_t* packet,
- size_t length,
- const PacketTime& packet_time) override;
-
- private:
- PacketReceiver* receiver_ = nullptr;
- };
-
// RunBaseTest overwrites the audio_state and the voice_engine of the send and
// receive Call configs to simplify test code and avoid having old VoiceEngine
// APIs in the tests.
@@ -141,9 +125,6 @@ class CallTest : public ::testing::Test {
rtc::scoped_refptr<AudioDecoderFactory> decoder_factory_;
test::FakeVideoRenderer fake_renderer_;
- PayloadDemuxer receive_demuxer_;
- PayloadDemuxer send_demuxer_;
-
private:
// TODO(holmer): Remove once VoiceEngine is fully refactored to the new API.
// These methods are used to set up legacy voice engines and channels which is
@@ -192,10 +173,6 @@ class BaseTest : public RtpRtcpObserver {
virtual Call::Config GetReceiverCallConfig();
virtual void OnCallsCreated(Call* sender_call, Call* receiver_call);
- // Returns VIDEO for video-only tests, AUDIO for audio-only tests,
- // and ANY for tests sending audio and video over the same
- // transport.
- virtual MediaType SelectMediaType();
virtual test::PacketTransport* CreateSendTransport(Call* sender_call);
virtual test::PacketTransport* CreateReceiveTransport();

Powered by Google App Engine
This is Rietveld 408576698