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

Unified Diff: webrtc/modules/audio_coding/neteq/neteq_impl_unittest.cc

Issue 1319683002: AudioDecoder: Replace Init() with Reset() (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@buffer
Patch Set: review fixes 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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_coding/neteq/neteq_impl_unittest.cc
diff --git a/webrtc/modules/audio_coding/neteq/neteq_impl_unittest.cc b/webrtc/modules/audio_coding/neteq/neteq_impl_unittest.cc
index 006a5ad542397cb839b2fe70bd5e59c093fbdbc8..ee04a6f255b2d8b03c1a5ed2a7124e6b85924e7b 100644
--- a/webrtc/modules/audio_coding/neteq/neteq_impl_unittest.cc
+++ b/webrtc/modules/audio_coding/neteq/neteq_impl_unittest.cc
@@ -444,10 +444,7 @@ TEST_F(NetEqImplTest, VerifyTimestampPropagation) {
return encoded_len;
}
- virtual int Init() {
- next_value_ = 1;
- return 0;
- }
+ void Reset() override { next_value_ = 1; }
size_t Channels() const override { return 1; }
@@ -524,7 +521,7 @@ TEST_F(NetEqImplTest, ReorderedPacket) {
// Create a mock decoder object.
MockAudioDecoder mock_decoder;
- EXPECT_CALL(mock_decoder, Init()).WillRepeatedly(Return(0));
+ EXPECT_CALL(mock_decoder, Reset()).WillRepeatedly(Return());
EXPECT_CALL(mock_decoder, Channels()).WillRepeatedly(Return(1));
EXPECT_CALL(mock_decoder, IncomingPacket(_, kPayloadLengthBytes, _, _, _))
.WillRepeatedly(Return(0));
@@ -690,7 +687,7 @@ TEST_F(NetEqImplTest, CodecInternalCng) {
// Create a mock decoder object.
MockAudioDecoder mock_decoder;
- EXPECT_CALL(mock_decoder, Init()).WillRepeatedly(Return(0));
+ EXPECT_CALL(mock_decoder, Reset()).WillRepeatedly(Return());
EXPECT_CALL(mock_decoder, Channels()).WillRepeatedly(Return(1));
EXPECT_CALL(mock_decoder, IncomingPacket(_, kPayloadLengthBytes, _, _, _))
.WillRepeatedly(Return(0));
@@ -829,9 +826,7 @@ TEST_F(NetEqImplTest, UnsupportedDecoder) {
class MockAudioDecoder : public AudioDecoder {
public:
- int Init() override {
- return 0;
- }
+ void Reset() override {}
MOCK_CONST_METHOD2(PacketDuration, int(const uint8_t*, size_t));
MOCK_METHOD5(DecodeInternal, int(const uint8_t*, size_t, int, int16_t*,
SpeechType*));
« no previous file with comments | « webrtc/modules/audio_coding/neteq/neteq_impl.cc ('k') | webrtc/modules/audio_coding/neteq/neteq_network_stats_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698