Don't expect factory to create iLBC decoder if it isn't supported

BUG=webrtc:7377

Review-Url: https://codereview.webrtc.org/2762153002
Cr-Commit-Position: refs/heads/master@{#17328}
This commit is contained in:
kwiberg
2017-03-21 12:16:51 -07:00
committed by Commit bot
parent 72acf25261
commit 14325edfe4

View File

@ -52,7 +52,9 @@ TEST(AudioDecoderFactoryTest, CreateIlbc) {
ASSERT_TRUE(adf);
// iLBC supports 8 kHz, 1 channel.
EXPECT_FALSE(adf->MakeAudioDecoder(SdpAudioFormat("ilbc", 8000, 0)));
#ifdef WEBRTC_CODEC_ILBC
EXPECT_TRUE(adf->MakeAudioDecoder(SdpAudioFormat("ilbc", 8000, 1)));
#endif
EXPECT_FALSE(adf->MakeAudioDecoder(SdpAudioFormat("ilbc", 8000, 2)));
EXPECT_FALSE(adf->MakeAudioDecoder(SdpAudioFormat("ilbc", 16000, 1)));
}