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

Side by Side Diff: webrtc/media/engine/webrtcvoiceengine_unittest.cc

Issue 2785443002: Remove VoECodec from FakeWebRtcVoiceEngine. (Closed)
Patch Set: one include too many 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 unified diff | Download patch
« no previous file with comments | « webrtc/media/engine/webrtcvoe.h ('k') | no next file » | 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 * Copyright (c) 2008 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2008 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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 const uint32_t kSsrcY = 0x17; 57 const uint32_t kSsrcY = 0x17;
58 const uint32_t kSsrcZ = 0x42; 58 const uint32_t kSsrcZ = 0x42;
59 const uint32_t kSsrcW = 0x02; 59 const uint32_t kSsrcW = 0x02;
60 const uint32_t kSsrcs4[] = { 11, 200, 30, 44 }; 60 const uint32_t kSsrcs4[] = { 11, 200, 30, 44 };
61 61
62 constexpr int kRtpHistoryMs = 5000; 62 constexpr int kRtpHistoryMs = 5000;
63 63
64 class FakeVoEWrapper : public cricket::VoEWrapper { 64 class FakeVoEWrapper : public cricket::VoEWrapper {
65 public: 65 public:
66 explicit FakeVoEWrapper(cricket::FakeWebRtcVoiceEngine* engine) 66 explicit FakeVoEWrapper(cricket::FakeWebRtcVoiceEngine* engine)
67 : cricket::VoEWrapper(engine, // base 67 : cricket::VoEWrapper(engine) {
68 engine) { // codec
69 } 68 }
70 }; 69 };
71 70
72 class MockTransmitMixer : public webrtc::voe::TransmitMixer { 71 class MockTransmitMixer : public webrtc::voe::TransmitMixer {
73 public: 72 public:
74 MockTransmitMixer() = default; 73 MockTransmitMixer() = default;
75 virtual ~MockTransmitMixer() = default; 74 virtual ~MockTransmitMixer() = default;
76 75
77 MOCK_METHOD1(EnableStereoChannelSwapping, void(bool enable)); 76 MOCK_METHOD1(EnableStereoChannelSwapping, void(bool enable));
78 }; 77 };
(...skipping 3763 matching lines...) Expand 10 before | Expand all | Expand 10 after
3842 // Without this cast, the comparison turned unsigned and, thus, failed for -1. 3841 // Without this cast, the comparison turned unsigned and, thus, failed for -1.
3843 const int num_specs = static_cast<int>(specs.size()); 3842 const int num_specs = static_cast<int>(specs.size());
3844 EXPECT_GE(find_codec({"cn", 8000, 1}), num_specs); 3843 EXPECT_GE(find_codec({"cn", 8000, 1}), num_specs);
3845 EXPECT_GE(find_codec({"cn", 16000, 1}), num_specs); 3844 EXPECT_GE(find_codec({"cn", 16000, 1}), num_specs);
3846 EXPECT_EQ(find_codec({"cn", 32000, 1}), -1); 3845 EXPECT_EQ(find_codec({"cn", 32000, 1}), -1);
3847 EXPECT_GE(find_codec({"telephone-event", 8000, 1}), num_specs); 3846 EXPECT_GE(find_codec({"telephone-event", 8000, 1}), num_specs);
3848 EXPECT_GE(find_codec({"telephone-event", 16000, 1}), num_specs); 3847 EXPECT_GE(find_codec({"telephone-event", 16000, 1}), num_specs);
3849 EXPECT_GE(find_codec({"telephone-event", 32000, 1}), num_specs); 3848 EXPECT_GE(find_codec({"telephone-event", 32000, 1}), num_specs);
3850 EXPECT_GE(find_codec({"telephone-event", 48000, 1}), num_specs); 3849 EXPECT_GE(find_codec({"telephone-event", 48000, 1}), num_specs);
3851 } 3850 }
OLDNEW
« no previous file with comments | « webrtc/media/engine/webrtcvoe.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698