pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 1 | /* |
| 2 | * libjingle |
| 3 | * Copyright 2004 Google Inc. |
| 4 | * |
| 5 | * Redistribution and use in source and binary forms, with or without |
| 6 | * modification, are permitted provided that the following conditions are met: |
| 7 | * |
| 8 | * 1. Redistributions of source code must retain the above copyright notice, |
| 9 | * this list of conditions and the following disclaimer. |
| 10 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
| 11 | * this list of conditions and the following disclaimer in the documentation |
| 12 | * and/or other materials provided with the distribution. |
| 13 | * 3. The name of the author may not be used to endorse or promote products |
| 14 | * derived from this software without specific prior written permission. |
| 15 | * |
| 16 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED |
| 17 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
| 18 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO |
| 19 | * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
| 20 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
| 21 | * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; |
| 22 | * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, |
| 23 | * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR |
| 24 | * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF |
| 25 | * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 26 | */ |
| 27 | |
| 28 | #include <map> |
| 29 | |
| 30 | #include "talk/base/gunit.h" |
| 31 | #include "talk/media/base/testutils.h" |
| 32 | #include "talk/media/base/videoengine_unittest.h" |
| 33 | #include "talk/media/webrtc/webrtcvideoengine2.h" |
| 34 | #include "talk/media/webrtc/webrtcvideochannelfactory.h" |
| 35 | #include "webrtc/call.h" |
| 36 | |
| 37 | namespace { |
| 38 | static const cricket::VideoCodec kVp8Codec720p(100, "VP8", 1280, 720, 30, 0); |
| 39 | static const cricket::VideoCodec kVp8Codec360p(100, "VP8", 640, 360, 30, 0); |
| 40 | static const cricket::VideoCodec kVp8Codec270p(100, "VP8", 480, 270, 30, 0); |
| 41 | static const cricket::VideoCodec kVp8Codec180p(100, "VP8", 320, 180, 30, 0); |
| 42 | |
| 43 | static const cricket::VideoCodec kVp8Codec(100, "VP8", 640, 400, 30, 0); |
| 44 | static const cricket::VideoCodec kVp9Codec(101, "VP9", 640, 400, 30, 0); |
| 45 | static const cricket::VideoCodec kRedCodec(116, "red", 0, 0, 0, 0); |
| 46 | static const cricket::VideoCodec kUlpfecCodec(117, "ulpfec", 0, 0, 0, 0); |
| 47 | |
| 48 | static const uint32 kSsrcs1[] = {1}; |
| 49 | static const uint32 kRtxSsrcs1[] = {4}; |
| 50 | } // namespace |
| 51 | |
| 52 | namespace cricket { |
| 53 | class FakeVideoSendStream : public webrtc::VideoSendStream { |
| 54 | public: |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 55 | FakeVideoSendStream(const webrtc::VideoSendStream::Config& config, |
| 56 | const std::vector<webrtc::VideoStream>& video_streams) |
| 57 | : sending_(false), config_(config), video_streams_(video_streams) {} |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 58 | |
| 59 | webrtc::VideoSendStream::Config GetConfig() { return config_; } |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 60 | std::vector<webrtc::VideoStream> GetVideoStreams() { return video_streams_; } |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 61 | |
| 62 | bool IsSending() { return sending_; } |
| 63 | |
| 64 | private: |
| 65 | virtual webrtc::VideoSendStream::Stats GetStats() const OVERRIDE { |
| 66 | return webrtc::VideoSendStream::Stats(); |
| 67 | } |
| 68 | |
| 69 | virtual bool ReconfigureVideoEncoder( |
| 70 | const std::vector<webrtc::VideoStream>& streams, |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 71 | const void* encoder_specific) OVERRIDE { |
| 72 | video_streams_ = streams; |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 73 | return true; |
| 74 | } |
| 75 | |
| 76 | virtual webrtc::VideoSendStreamInput* Input() OVERRIDE { |
| 77 | // TODO(pbos): Fix. |
| 78 | return NULL; |
| 79 | } |
| 80 | |
| 81 | virtual void Start() OVERRIDE { sending_ = true; } |
| 82 | |
| 83 | virtual void Stop() OVERRIDE { sending_ = false; } |
| 84 | |
| 85 | bool sending_; |
| 86 | webrtc::VideoSendStream::Config config_; |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 87 | std::vector<webrtc::VideoStream> video_streams_; |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 88 | }; |
| 89 | |
| 90 | class FakeVideoReceiveStream : public webrtc::VideoReceiveStream { |
| 91 | public: |
| 92 | explicit FakeVideoReceiveStream( |
| 93 | const webrtc::VideoReceiveStream::Config& config) |
| 94 | : config_(config), receiving_(false) {} |
| 95 | |
| 96 | webrtc::VideoReceiveStream::Config GetConfig() { return config_; } |
| 97 | |
| 98 | private: |
| 99 | virtual webrtc::VideoReceiveStream::Stats GetStats() const OVERRIDE { |
| 100 | return webrtc::VideoReceiveStream::Stats(); |
| 101 | } |
| 102 | |
| 103 | virtual void Start() OVERRIDE { receiving_ = true; } |
| 104 | virtual void Stop() OVERRIDE { receiving_ = false; } |
| 105 | virtual void GetCurrentReceiveCodec(webrtc::VideoCodec* codec) OVERRIDE {} |
| 106 | |
| 107 | webrtc::VideoReceiveStream::Config config_; |
| 108 | bool receiving_; |
| 109 | }; |
| 110 | |
| 111 | class FakeCall : public webrtc::Call { |
| 112 | public: |
| 113 | FakeCall() { SetVideoCodecs(GetDefaultVideoCodecs()); } |
| 114 | |
| 115 | ~FakeCall() { |
| 116 | EXPECT_EQ(0u, video_send_streams_.size()); |
| 117 | EXPECT_EQ(0u, video_receive_streams_.size()); |
| 118 | } |
| 119 | |
| 120 | void SetVideoCodecs(const std::vector<webrtc::VideoCodec> codecs) { |
| 121 | codecs_ = codecs; |
| 122 | } |
| 123 | |
| 124 | std::vector<FakeVideoSendStream*> GetVideoSendStreams() { |
| 125 | return video_send_streams_; |
| 126 | } |
| 127 | |
| 128 | std::vector<FakeVideoReceiveStream*> GetVideoReceiveStreams() { |
| 129 | return video_receive_streams_; |
| 130 | } |
| 131 | |
| 132 | webrtc::VideoCodec GetEmptyVideoCodec() { |
| 133 | webrtc::VideoCodec codec; |
| 134 | codec.minBitrate = 300; |
| 135 | codec.startBitrate = 800; |
| 136 | codec.maxBitrate = 1500; |
| 137 | codec.maxFramerate = 10; |
| 138 | codec.width = 640; |
| 139 | codec.height = 480; |
| 140 | codec.qpMax = 56; |
| 141 | |
| 142 | return codec; |
| 143 | } |
| 144 | |
| 145 | webrtc::VideoCodec GetVideoCodecVp8() { |
| 146 | webrtc::VideoCodec vp8_codec = GetEmptyVideoCodec(); |
| 147 | vp8_codec.codecType = webrtc::kVideoCodecVP8; |
| 148 | strcpy(vp8_codec.plName, kVp8Codec.name.c_str()); |
| 149 | vp8_codec.plType = kVp8Codec.id; |
| 150 | |
| 151 | return vp8_codec; |
| 152 | } |
| 153 | |
| 154 | webrtc::VideoCodec GetVideoCodecVp9() { |
| 155 | webrtc::VideoCodec vp9_codec = GetEmptyVideoCodec(); |
| 156 | // TODO(pbos): Add a correct codecType when webrtc has one. |
| 157 | vp9_codec.codecType = webrtc::kVideoCodecVP8; |
| 158 | strcpy(vp9_codec.plName, kVp9Codec.name.c_str()); |
| 159 | vp9_codec.plType = kVp9Codec.id; |
| 160 | |
| 161 | return vp9_codec; |
| 162 | } |
| 163 | |
| 164 | std::vector<webrtc::VideoCodec> GetDefaultVideoCodecs() { |
| 165 | std::vector<webrtc::VideoCodec> codecs; |
| 166 | codecs.push_back(GetVideoCodecVp8()); |
| 167 | // codecs.push_back(GetVideoCodecVp9()); |
| 168 | |
| 169 | return codecs; |
| 170 | } |
| 171 | |
| 172 | private: |
| 173 | virtual webrtc::VideoSendStream::Config GetDefaultSendConfig() OVERRIDE { |
| 174 | webrtc::VideoSendStream::Config config; |
| 175 | // TODO(pbos): Encoder settings. |
| 176 | // config.codec = GetVideoCodecVp8(); |
| 177 | return config; |
| 178 | } |
| 179 | |
| 180 | virtual webrtc::VideoSendStream* CreateVideoSendStream( |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 181 | const webrtc::VideoSendStream::Config& config, |
| 182 | const std::vector<webrtc::VideoStream>& video_streams, |
| 183 | const void* encoder_settings) OVERRIDE { |
| 184 | FakeVideoSendStream* fake_stream = |
| 185 | new FakeVideoSendStream(config, video_streams); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 186 | video_send_streams_.push_back(fake_stream); |
| 187 | return fake_stream; |
| 188 | } |
| 189 | |
| 190 | virtual void DestroyVideoSendStream(webrtc::VideoSendStream* send_stream) |
| 191 | OVERRIDE { |
| 192 | FakeVideoSendStream* fake_stream = |
| 193 | static_cast<FakeVideoSendStream*>(send_stream); |
| 194 | for (size_t i = 0; i < video_send_streams_.size(); ++i) { |
| 195 | if (video_send_streams_[i] == fake_stream) { |
| 196 | delete video_send_streams_[i]; |
| 197 | video_send_streams_.erase(video_send_streams_.begin() + i); |
| 198 | return; |
| 199 | } |
| 200 | } |
| 201 | ADD_FAILURE() << "DestroyVideoSendStream called with unknown paramter."; |
| 202 | } |
| 203 | |
| 204 | virtual webrtc::VideoReceiveStream::Config GetDefaultReceiveConfig() |
| 205 | OVERRIDE { |
| 206 | return webrtc::VideoReceiveStream::Config(); |
| 207 | } |
| 208 | |
| 209 | virtual webrtc::VideoReceiveStream* CreateVideoReceiveStream( |
| 210 | const webrtc::VideoReceiveStream::Config& config) OVERRIDE { |
| 211 | video_receive_streams_.push_back(new FakeVideoReceiveStream(config)); |
| 212 | return video_receive_streams_[video_receive_streams_.size() - 1]; |
| 213 | } |
| 214 | |
| 215 | virtual void DestroyVideoReceiveStream( |
| 216 | webrtc::VideoReceiveStream* receive_stream) OVERRIDE { |
| 217 | FakeVideoReceiveStream* fake_stream = |
| 218 | static_cast<FakeVideoReceiveStream*>(receive_stream); |
| 219 | for (size_t i = 0; i < video_receive_streams_.size(); ++i) { |
| 220 | if (video_receive_streams_[i] == fake_stream) { |
| 221 | delete video_receive_streams_[i]; |
| 222 | video_receive_streams_.erase(video_receive_streams_.begin() + i); |
| 223 | return; |
| 224 | } |
| 225 | } |
| 226 | ADD_FAILURE() << "DestroyVideoReceiveStream called with unknown paramter."; |
| 227 | } |
| 228 | |
| 229 | virtual webrtc::PacketReceiver* Receiver() OVERRIDE { |
| 230 | // TODO(pbos): Fix this. |
| 231 | return NULL; |
| 232 | } |
| 233 | |
| 234 | virtual uint32_t SendBitrateEstimate() OVERRIDE { return 0; } |
| 235 | |
| 236 | virtual uint32_t ReceiveBitrateEstimate() OVERRIDE { return 0; } |
| 237 | |
| 238 | private: |
| 239 | std::vector<webrtc::VideoCodec> codecs_; |
| 240 | std::vector<FakeVideoSendStream*> video_send_streams_; |
| 241 | std::vector<FakeVideoReceiveStream*> video_receive_streams_; |
| 242 | }; |
| 243 | |
| 244 | class FakeWebRtcVideoChannel2 : public WebRtcVideoChannel2 { |
| 245 | public: |
| 246 | FakeWebRtcVideoChannel2(FakeCall* call, |
| 247 | WebRtcVideoEngine2* engine, |
| 248 | VoiceMediaChannel* voice_channel) |
pbos@webrtc.org | b931d7e | 2014-06-05 09:10:55 +0000 | [diff] [blame] | 249 | : WebRtcVideoChannel2(call, engine, engine->GetVideoEncoderFactory()), |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 250 | fake_call_(call), |
| 251 | voice_channel_(voice_channel) {} |
| 252 | |
| 253 | virtual ~FakeWebRtcVideoChannel2() {} |
| 254 | |
| 255 | VoiceMediaChannel* GetVoiceChannel() { return voice_channel_; } |
| 256 | FakeCall* GetFakeCall() { return fake_call_; } |
| 257 | |
| 258 | private: |
| 259 | FakeCall* fake_call_; |
| 260 | VoiceMediaChannel* voice_channel_; |
| 261 | }; |
| 262 | |
| 263 | class FakeWebRtcVideoMediaChannelFactory : public WebRtcVideoChannelFactory { |
| 264 | public: |
| 265 | FakeWebRtcVideoChannel2* GetFakeChannel(VideoMediaChannel* channel) { |
| 266 | return channel_map_[channel]; |
| 267 | } |
| 268 | |
| 269 | private: |
| 270 | virtual WebRtcVideoChannel2* Create(WebRtcVideoEngine2* engine, |
| 271 | VoiceMediaChannel* voice_channel) |
| 272 | OVERRIDE { |
| 273 | FakeWebRtcVideoChannel2* channel = |
| 274 | new FakeWebRtcVideoChannel2(new FakeCall(), engine, voice_channel); |
| 275 | channel_map_[channel] = channel; |
| 276 | return channel; |
| 277 | } |
| 278 | |
| 279 | std::map<VideoMediaChannel*, FakeWebRtcVideoChannel2*> channel_map_; |
| 280 | }; |
| 281 | |
| 282 | class WebRtcVideoEngine2Test : public testing::Test { |
| 283 | public: |
| 284 | WebRtcVideoEngine2Test() |
| 285 | : engine_(&factory_), engine_codecs_(engine_.codecs()) { |
| 286 | assert(!engine_codecs_.empty()); |
| 287 | bool codec_set = false; |
| 288 | for (size_t i = 0; i < engine_codecs_.size(); ++i) { |
| 289 | if (engine_codecs_[i].name == "red") { |
| 290 | default_red_codec_ = engine_codecs_[i]; |
| 291 | } else if (engine_codecs_[i].name == "ulpfec") { |
| 292 | default_ulpfec_codec_ = engine_codecs_[i]; |
| 293 | } else if (engine_codecs_[i].name == "rtx") { |
| 294 | default_rtx_codec_ = engine_codecs_[i]; |
| 295 | } else if (!codec_set) { |
| 296 | default_codec_ = engine_codecs_[i]; |
| 297 | codec_set = true; |
| 298 | } |
| 299 | } |
| 300 | |
| 301 | assert(codec_set); |
| 302 | } |
| 303 | |
| 304 | protected: |
| 305 | FakeWebRtcVideoMediaChannelFactory factory_; |
| 306 | WebRtcVideoEngine2 engine_; |
| 307 | VideoCodec default_codec_; |
| 308 | VideoCodec default_red_codec_; |
| 309 | VideoCodec default_ulpfec_codec_; |
| 310 | VideoCodec default_rtx_codec_; |
| 311 | // TODO(pbos): Remove engine_codecs_ unless used a lot. |
| 312 | std::vector<VideoCodec> engine_codecs_; |
| 313 | }; |
| 314 | |
| 315 | TEST_F(WebRtcVideoEngine2Test, CreateChannel) { |
| 316 | talk_base::scoped_ptr<VideoMediaChannel> channel(engine_.CreateChannel(NULL)); |
| 317 | ASSERT_TRUE(channel.get() != NULL) << "Could not create channel."; |
| 318 | EXPECT_TRUE(factory_.GetFakeChannel(channel.get()) != NULL) |
| 319 | << "Channel not created through factory."; |
| 320 | } |
| 321 | |
| 322 | TEST_F(WebRtcVideoEngine2Test, CreateChannelWithVoiceEngine) { |
| 323 | VoiceMediaChannel* voice_channel = reinterpret_cast<VoiceMediaChannel*>(0x42); |
| 324 | talk_base::scoped_ptr<VideoMediaChannel> channel( |
| 325 | engine_.CreateChannel(voice_channel)); |
| 326 | ASSERT_TRUE(channel.get() != NULL) << "Could not create channel."; |
| 327 | |
| 328 | FakeWebRtcVideoChannel2* fake_channel = |
| 329 | factory_.GetFakeChannel(channel.get()); |
| 330 | ASSERT_TRUE(fake_channel != NULL) << "Channel not created through factory."; |
| 331 | |
| 332 | EXPECT_TRUE(fake_channel->GetVoiceChannel() != NULL) |
| 333 | << "VoiceChannel not set."; |
| 334 | EXPECT_EQ(voice_channel, fake_channel->GetVoiceChannel()) |
| 335 | << "Different VoiceChannel set than the provided one."; |
| 336 | } |
| 337 | |
| 338 | class WebRtcVideoChannel2BaseTest |
| 339 | : public VideoMediaChannelTest<WebRtcVideoEngine2, WebRtcVideoChannel2> { |
| 340 | protected: |
| 341 | virtual cricket::VideoCodec DefaultCodec() OVERRIDE { return kVp8Codec; } |
| 342 | typedef VideoMediaChannelTest<WebRtcVideoEngine2, WebRtcVideoChannel2> Base; |
| 343 | }; |
| 344 | |
| 345 | // TODO(pbos): Fix WebRtcVideoEngine2BaseTest, where we want CheckCoInitialize. |
| 346 | #if 0 |
| 347 | // TODO(juberti): Figure out why ViE is munging the COM refcount. |
| 348 | #ifdef WIN32 |
| 349 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_CheckCoInitialize) { |
| 350 | Base::CheckCoInitialize(); |
| 351 | } |
| 352 | #endif |
| 353 | #endif |
| 354 | |
| 355 | TEST_F(WebRtcVideoChannel2BaseTest, SetSend) { Base::SetSend(); } |
| 356 | |
| 357 | TEST_F(WebRtcVideoChannel2BaseTest, SetSendWithoutCodecs) { |
| 358 | Base::SetSendWithoutCodecs(); |
| 359 | } |
| 360 | |
| 361 | TEST_F(WebRtcVideoChannel2BaseTest, SetSendSetsTransportBufferSizes) { |
| 362 | Base::SetSendSetsTransportBufferSizes(); |
| 363 | } |
| 364 | |
| 365 | // TODO(juberti): Fix this test to tolerate missing stats. |
| 366 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_GetStats) { Base::GetStats(); } |
| 367 | |
| 368 | // TODO(juberti): Fix this test to tolerate missing stats. |
| 369 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_GetStatsMultipleRecvStreams) { |
| 370 | Base::GetStatsMultipleRecvStreams(); |
| 371 | } |
| 372 | |
| 373 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_GetStatsMultipleSendStreams) { |
| 374 | Base::GetStatsMultipleSendStreams(); |
| 375 | } |
| 376 | |
| 377 | TEST_F(WebRtcVideoChannel2BaseTest, SetSendBandwidth) { |
| 378 | Base::SetSendBandwidth(); |
| 379 | } |
| 380 | TEST_F(WebRtcVideoChannel2BaseTest, SetSendSsrc) { Base::SetSendSsrc(); } |
| 381 | TEST_F(WebRtcVideoChannel2BaseTest, SetSendSsrcAfterSetCodecs) { |
| 382 | Base::SetSendSsrcAfterSetCodecs(); |
| 383 | } |
| 384 | |
| 385 | TEST_F(WebRtcVideoChannel2BaseTest, SetRenderer) { Base::SetRenderer(); } |
| 386 | |
| 387 | TEST_F(WebRtcVideoChannel2BaseTest, AddRemoveRecvStreams) { |
| 388 | Base::AddRemoveRecvStreams(); |
| 389 | } |
| 390 | |
| 391 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_AddRemoveRecvStreamAndRender) { |
| 392 | Base::AddRemoveRecvStreamAndRender(); |
| 393 | } |
| 394 | |
| 395 | TEST_F(WebRtcVideoChannel2BaseTest, AddRemoveRecvStreamsNoConference) { |
| 396 | Base::AddRemoveRecvStreamsNoConference(); |
| 397 | } |
| 398 | |
| 399 | TEST_F(WebRtcVideoChannel2BaseTest, AddRemoveSendStreams) { |
| 400 | Base::AddRemoveSendStreams(); |
| 401 | } |
| 402 | |
| 403 | TEST_F(WebRtcVideoChannel2BaseTest, SimulateConference) { |
| 404 | Base::SimulateConference(); |
| 405 | } |
| 406 | |
| 407 | TEST_F(WebRtcVideoChannel2BaseTest, AddRemoveCapturer) { |
| 408 | Base::AddRemoveCapturer(); |
| 409 | } |
| 410 | |
| 411 | TEST_F(WebRtcVideoChannel2BaseTest, RemoveCapturerWithoutAdd) { |
| 412 | Base::RemoveCapturerWithoutAdd(); |
| 413 | } |
| 414 | |
| 415 | TEST_F(WebRtcVideoChannel2BaseTest, AddRemoveCapturerMultipleSources) { |
| 416 | Base::AddRemoveCapturerMultipleSources(); |
| 417 | } |
| 418 | |
| 419 | // TODO(pbos): Figure out why this fails so often. |
| 420 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_HighAspectHighHeightCapturer) { |
| 421 | Base::HighAspectHighHeightCapturer(); |
| 422 | } |
| 423 | |
| 424 | TEST_F(WebRtcVideoChannel2BaseTest, RejectEmptyStreamParams) { |
| 425 | Base::RejectEmptyStreamParams(); |
| 426 | } |
| 427 | |
| 428 | TEST_F(WebRtcVideoChannel2BaseTest, AdaptResolution16x10) { |
| 429 | Base::AdaptResolution16x10(); |
| 430 | } |
| 431 | |
| 432 | TEST_F(WebRtcVideoChannel2BaseTest, AdaptResolution4x3) { |
| 433 | Base::AdaptResolution4x3(); |
| 434 | } |
| 435 | |
| 436 | TEST_F(WebRtcVideoChannel2BaseTest, MuteStream) { Base::MuteStream(); } |
| 437 | |
| 438 | TEST_F(WebRtcVideoChannel2BaseTest, MultipleSendStreams) { |
| 439 | Base::MultipleSendStreams(); |
| 440 | } |
| 441 | |
| 442 | // TODO(juberti): Restore this test once we support sending 0 fps. |
| 443 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_AdaptDropAllFrames) { |
| 444 | Base::AdaptDropAllFrames(); |
| 445 | } |
| 446 | // TODO(juberti): Understand why we get decode errors on this test. |
| 447 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_AdaptFramerate) { |
| 448 | Base::AdaptFramerate(); |
| 449 | } |
| 450 | |
| 451 | TEST_F(WebRtcVideoChannel2BaseTest, SetSendStreamFormat0x0) { |
| 452 | Base::SetSendStreamFormat0x0(); |
| 453 | } |
| 454 | |
| 455 | // TODO(zhurunz): Fix the flakey test. |
| 456 | TEST_F(WebRtcVideoChannel2BaseTest, DISABLED_SetSendStreamFormat) { |
| 457 | Base::SetSendStreamFormat(); |
| 458 | } |
| 459 | |
| 460 | TEST_F(WebRtcVideoChannel2BaseTest, TwoStreamsSendAndReceive) { |
| 461 | Base::TwoStreamsSendAndReceive(kVp8Codec); |
| 462 | } |
| 463 | |
| 464 | TEST_F(WebRtcVideoChannel2BaseTest, TwoStreamsReUseFirstStream) { |
| 465 | Base::TwoStreamsReUseFirstStream(kVp8Codec); |
| 466 | } |
| 467 | |
| 468 | class WebRtcVideoChannel2Test : public WebRtcVideoEngine2Test { |
| 469 | public: |
| 470 | virtual void SetUp() OVERRIDE { |
| 471 | channel_.reset(engine_.CreateChannel(NULL)); |
| 472 | fake_channel_ = factory_.GetFakeChannel(channel_.get()); |
| 473 | last_ssrc_ = 123; |
| 474 | ASSERT_TRUE(fake_channel_ != NULL) |
| 475 | << "Channel not created through factory."; |
| 476 | } |
| 477 | |
| 478 | protected: |
| 479 | FakeVideoSendStream* AddSendStream() { |
| 480 | return AddSendStream(StreamParams::CreateLegacy(last_ssrc_++)); |
| 481 | } |
| 482 | |
| 483 | FakeVideoSendStream* AddSendStream(const StreamParams& sp) { |
| 484 | size_t num_streams = |
| 485 | fake_channel_->GetFakeCall()->GetVideoSendStreams().size(); |
| 486 | EXPECT_TRUE(channel_->AddSendStream(sp)); |
| 487 | std::vector<FakeVideoSendStream*> streams = |
| 488 | fake_channel_->GetFakeCall()->GetVideoSendStreams(); |
| 489 | EXPECT_EQ(num_streams + 1, streams.size()); |
| 490 | return streams[streams.size() - 1]; |
| 491 | } |
| 492 | |
| 493 | std::vector<FakeVideoSendStream*> GetFakeSendStreams() { |
| 494 | return fake_channel_->GetFakeCall()->GetVideoSendStreams(); |
| 495 | } |
| 496 | |
| 497 | FakeVideoReceiveStream* AddRecvStream() { |
| 498 | return AddRecvStream(StreamParams::CreateLegacy(last_ssrc_++)); |
| 499 | } |
| 500 | |
| 501 | FakeVideoReceiveStream* AddRecvStream(const StreamParams& sp) { |
| 502 | size_t num_streams = |
| 503 | fake_channel_->GetFakeCall()->GetVideoReceiveStreams().size(); |
| 504 | EXPECT_TRUE(channel_->AddRecvStream(sp)); |
| 505 | std::vector<FakeVideoReceiveStream*> streams = |
| 506 | fake_channel_->GetFakeCall()->GetVideoReceiveStreams(); |
| 507 | EXPECT_EQ(num_streams + 1, streams.size()); |
| 508 | return streams[streams.size() - 1]; |
| 509 | } |
| 510 | |
| 511 | void SetSendCodecsShouldWorkForBitrates(const char* min_bitrate, |
| 512 | const char* max_bitrate) { |
| 513 | std::vector<VideoCodec> codecs; |
| 514 | codecs.push_back(kVp8Codec); |
| 515 | codecs[0].params[kCodecParamMinBitrate] = min_bitrate; |
| 516 | codecs[0].params[kCodecParamMaxBitrate] = max_bitrate; |
| 517 | EXPECT_TRUE(channel_->SetSendCodecs(codecs)); |
| 518 | |
| 519 | FakeVideoSendStream* stream = AddSendStream(); |
| 520 | |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 521 | std::vector<webrtc::VideoStream> video_streams = stream->GetVideoStreams(); |
| 522 | ASSERT_EQ(1u, video_streams.size()); |
| 523 | EXPECT_EQ(atoi(min_bitrate), video_streams.back().min_bitrate_bps / 1000); |
| 524 | EXPECT_EQ(atoi(max_bitrate), video_streams.back().max_bitrate_bps / 1000); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 525 | |
| 526 | VideoCodec codec; |
| 527 | EXPECT_TRUE(channel_->GetSendCodec(&codec)); |
| 528 | EXPECT_EQ(min_bitrate, codec.params[kCodecParamMinBitrate]); |
| 529 | EXPECT_EQ(max_bitrate, codec.params[kCodecParamMaxBitrate]); |
| 530 | } |
| 531 | |
| 532 | void ExpectEqualCodecs(const VideoCodec video_codec, |
| 533 | const webrtc::VideoCodec& webrtc_codec) { |
| 534 | EXPECT_STREQ(video_codec.name.c_str(), webrtc_codec.plName); |
| 535 | EXPECT_EQ(video_codec.id, webrtc_codec.plType); |
| 536 | EXPECT_EQ(video_codec.width, webrtc_codec.width); |
| 537 | EXPECT_EQ(video_codec.height, webrtc_codec.height); |
| 538 | EXPECT_EQ(video_codec.framerate, webrtc_codec.maxFramerate); |
| 539 | } |
| 540 | talk_base::scoped_ptr<VideoMediaChannel> channel_; |
| 541 | FakeWebRtcVideoChannel2* fake_channel_; |
| 542 | uint32 last_ssrc_; |
| 543 | }; |
| 544 | |
| 545 | TEST_F(WebRtcVideoChannel2Test, DISABLED_MaxBitrateResetsWithConferenceMode) { |
| 546 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 547 | } |
| 548 | |
| 549 | TEST_F(WebRtcVideoChannel2Test, DISABLED_StartSendBitrate) { |
| 550 | // TODO(pbos): Is this test testing vie_ ? this is confusing. No API to set |
| 551 | // start send bitrate from outside? Add defaults here that should be kept? |
| 552 | std::vector<cricket::VideoCodec> codec_list; |
| 553 | codec_list.push_back(kVp8Codec); |
| 554 | EXPECT_TRUE(channel_->SetSendCodecs(codec_list)); |
| 555 | const unsigned int kVideoMinSendBitrateKbps = 50; |
| 556 | const unsigned int kVideoTargetSendBitrateKbps = 300; |
| 557 | const unsigned int kVideoMaxSendBitrateKbps = 2000; |
| 558 | FakeVideoSendStream* stream = AddSendStream(); |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 559 | std::vector<webrtc::VideoStream> video_streams = stream->GetVideoStreams(); |
| 560 | ASSERT_EQ(1u, video_streams.size()); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 561 | EXPECT_EQ(kVideoMinSendBitrateKbps, |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 562 | video_streams.back().min_bitrate_bps / 1000); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 563 | EXPECT_EQ(kVideoTargetSendBitrateKbps, |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 564 | video_streams.back().target_bitrate_bps / 1000); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 565 | EXPECT_EQ(kVideoMaxSendBitrateKbps, |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 566 | video_streams.back().max_bitrate_bps / 1000); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 567 | #if 0 |
| 568 | // TODO(pbos): un-#if |
| 569 | VerifyVP8SendCodec(send_channel, kVP8Codec.width, kVP8Codec.height, 0, |
| 570 | kVideoMaxSendBitrateKbps, kVideoMinSendBitrateKbps, |
| 571 | kVideoDefaultStartSendBitrateKbps); |
| 572 | EXPECT_EQ(0, vie_.StartSend(send_channel)); |
| 573 | |
| 574 | // Increase the send bitrate and verify it is used as start bitrate. |
| 575 | const unsigned int kVideoSendBitrateBps = 768000; |
| 576 | vie_.SetSendBitrates(send_channel, kVideoSendBitrateBps, 0, 0); |
| 577 | EXPECT_TRUE(channel_->SetSendCodecs(codec_list)); |
| 578 | VerifyVP8SendCodec(send_channel, kVP8Codec.width, kVP8Codec.height, 0, |
| 579 | kVideoMaxSendBitrateKbps, kVideoMinSendBitrateKbps, |
| 580 | kVideoSendBitrateBps / 1000); |
| 581 | |
| 582 | // Never set a start bitrate higher than the max bitrate. |
| 583 | vie_.SetSendBitrates(send_channel, kVideoMaxSendBitrateKbps + 500, 0, 0); |
| 584 | EXPECT_TRUE(channel_->SetSendCodecs(codec_list)); |
| 585 | VerifyVP8SendCodec(send_channel, kVP8Codec.width, kVP8Codec.height, 0, |
| 586 | kVideoMaxSendBitrateKbps, kVideoMinSendBitrateKbps, |
| 587 | kVideoDefaultStartSendBitrateKbps); |
| 588 | |
| 589 | // Use the default start bitrate if the send bitrate is lower. |
| 590 | vie_.SetSendBitrates(send_channel, kVideoDefaultStartSendBitrateKbps - 50, 0, |
| 591 | 0); |
| 592 | EXPECT_TRUE(channel_->SetSendCodecs(codec_list)); |
| 593 | VerifyVP8SendCodec(send_channel, kVP8Codec.width, kVP8Codec.height, 0, |
| 594 | kVideoMaxSendBitrateKbps, kVideoMinSendBitrateKbps, |
| 595 | kVideoDefaultStartSendBitrateKbps); |
| 596 | #endif |
| 597 | } |
| 598 | |
| 599 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RtcpEnabled) { |
| 600 | // Note(pbos): This is a receiver-side setting, dumbo. |
| 601 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 602 | } |
| 603 | |
| 604 | TEST_F(WebRtcVideoChannel2Test, DISABLED_KeyFrameRequestEnabled) { |
| 605 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 606 | } |
| 607 | |
| 608 | TEST_F(WebRtcVideoChannel2Test, RembIsEnabledByDefault) { |
| 609 | FakeVideoReceiveStream* stream = AddRecvStream(); |
| 610 | EXPECT_TRUE(stream->GetConfig().rtp.remb); |
| 611 | } |
| 612 | |
| 613 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RembEnabledOnReceiveChannels) { |
| 614 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 615 | } |
| 616 | |
| 617 | TEST_F(WebRtcVideoChannel2Test, RecvStreamWithRtx) { |
| 618 | EXPECT_TRUE(channel_->SetSendCodecs(engine_.codecs())); |
| 619 | EXPECT_TRUE(channel_->SetSend(true)); |
| 620 | cricket::VideoOptions options; |
| 621 | options.conference_mode.Set(true); |
| 622 | EXPECT_TRUE(channel_->SetOptions(options)); |
| 623 | |
| 624 | // Send side. |
| 625 | const std::vector<uint32> ssrcs = MAKE_VECTOR(kSsrcs1); |
| 626 | const std::vector<uint32> rtx_ssrcs = MAKE_VECTOR(kRtxSsrcs1); |
| 627 | FakeVideoSendStream* send_stream = AddSendStream( |
| 628 | cricket::CreateSimWithRtxStreamParams("cname", ssrcs, rtx_ssrcs)); |
| 629 | |
| 630 | ASSERT_EQ(rtx_ssrcs.size(), send_stream->GetConfig().rtp.rtx.ssrcs.size()); |
| 631 | for (size_t i = 0; i < rtx_ssrcs.size(); ++i) |
| 632 | EXPECT_EQ(rtx_ssrcs[i], send_stream->GetConfig().rtp.rtx.ssrcs[i]); |
| 633 | |
| 634 | // Receiver side. |
| 635 | FakeVideoReceiveStream* recv_stream = AddRecvStream( |
| 636 | cricket::CreateSimWithRtxStreamParams("cname", ssrcs, rtx_ssrcs)); |
| 637 | ASSERT_GT(recv_stream->GetConfig().rtp.rtx.size(), 0u) |
| 638 | << "No SSRCs for RTX configured by AddRecvStream."; |
| 639 | ASSERT_EQ(1u, recv_stream->GetConfig().rtp.rtx.size()) |
| 640 | << "This test only works with one receive codec. Please update the test."; |
| 641 | EXPECT_EQ(rtx_ssrcs[0], |
| 642 | recv_stream->GetConfig().rtp.rtx.begin()->second.ssrc); |
| 643 | // TODO(pbos): Make sure we set the RTX for correct payloads etc. |
| 644 | } |
| 645 | |
| 646 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RecvStreamWithRtxOnMultiplePayloads) { |
| 647 | FAIL() << "Not implemented."; |
| 648 | } |
| 649 | |
buildbot@webrtc.org | 50f1b41 | 2014-05-30 07:40:35 +0000 | [diff] [blame] | 650 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RecvStreamNoRtx) { |
| 651 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 652 | } |
| 653 | |
| 654 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RtpTimestampOffsetHeaderExtensions) { |
| 655 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 656 | } |
| 657 | |
| 658 | TEST_F(WebRtcVideoChannel2Test, DISABLED_AbsoluteSendTimeHeaderExtensions) { |
| 659 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 660 | } |
| 661 | |
| 662 | TEST_F(WebRtcVideoChannel2Test, DISABLED_LeakyBucketTest) { |
| 663 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 664 | } |
| 665 | |
| 666 | TEST_F(WebRtcVideoChannel2Test, DISABLED_BufferedModeLatency) { |
| 667 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 668 | } |
| 669 | |
| 670 | TEST_F(WebRtcVideoChannel2Test, DISABLED_AdditiveVideoOptions) { |
| 671 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 672 | } |
| 673 | |
| 674 | TEST_F(WebRtcVideoChannel2Test, AddRecvStreamOnlyUsesOneReceiveStream) { |
| 675 | EXPECT_TRUE(channel_->AddRecvStream(cricket::StreamParams::CreateLegacy(1))); |
| 676 | EXPECT_EQ(1u, fake_channel_->GetFakeCall()->GetVideoReceiveStreams().size()); |
| 677 | } |
| 678 | |
| 679 | TEST_F(WebRtcVideoChannel2Test, DISABLED_NoRembChangeAfterAddRecvStream) { |
| 680 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 681 | } |
| 682 | |
| 683 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RembOnOff) { |
| 684 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 685 | } |
| 686 | |
pbos@webrtc.org | 84f5e34 | 2014-05-30 07:35:47 +0000 | [diff] [blame] | 687 | TEST_F(WebRtcVideoChannel2Test, NackIsEnabled) { |
| 688 | EXPECT_TRUE(channel_->SetSendCodecs(engine_.codecs())); |
| 689 | EXPECT_TRUE(channel_->SetSend(true)); |
| 690 | |
| 691 | // Send side. |
| 692 | FakeVideoSendStream* send_stream = |
| 693 | AddSendStream(cricket::StreamParams::CreateLegacy(1)); |
| 694 | EXPECT_GT(send_stream->GetConfig().rtp.nack.rtp_history_ms, 0); |
| 695 | |
| 696 | // Receiver side. |
| 697 | FakeVideoReceiveStream* recv_stream = |
| 698 | AddRecvStream(cricket::StreamParams::CreateLegacy(1)); |
| 699 | EXPECT_GT(recv_stream->GetConfig().rtp.nack.rtp_history_ms, 0); |
| 700 | |
| 701 | // Nack history size should match between sender and receiver. |
| 702 | EXPECT_EQ(send_stream->GetConfig().rtp.nack.rtp_history_ms, |
| 703 | recv_stream->GetConfig().rtp.nack.rtp_history_ms); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 704 | } |
| 705 | |
| 706 | TEST_F(WebRtcVideoChannel2Test, DISABLED_VideoProtectionInterop) { |
| 707 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 708 | } |
| 709 | |
| 710 | TEST_F(WebRtcVideoChannel2Test, DISABLED_VideoProtectionInteropReversed) { |
| 711 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 712 | } |
| 713 | |
| 714 | TEST_F(WebRtcVideoChannel2Test, DISABLED_HybridNackFecConference) { |
| 715 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 716 | } |
| 717 | |
| 718 | TEST_F(WebRtcVideoChannel2Test, DISABLED_AddRemoveRecvStreamConference) { |
| 719 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 720 | } |
| 721 | |
| 722 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetRender) { |
| 723 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 724 | } |
| 725 | |
| 726 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetBandwidthAuto) { |
| 727 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 728 | } |
| 729 | |
| 730 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetBandwidthAutoCapped) { |
| 731 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 732 | } |
| 733 | |
| 734 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetBandwidthFixed) { |
| 735 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 736 | } |
| 737 | |
| 738 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetBandwidthInConference) { |
| 739 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 740 | } |
| 741 | |
| 742 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetBandwidthScreencast) { |
| 743 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 744 | } |
| 745 | |
| 746 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetSendSsrcAndCname) { |
| 747 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 748 | } |
| 749 | |
| 750 | TEST_F(WebRtcVideoChannel2Test, |
| 751 | DISABLED_SetSendSsrcAfterCreatingReceiveChannel) { |
| 752 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 753 | } |
| 754 | |
| 755 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetOptionsWithDenoising) { |
| 756 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 757 | } |
| 758 | |
| 759 | TEST_F(WebRtcVideoChannel2Test, DISABLED_MultipleSendStreamsWithOneCapturer) { |
| 760 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 761 | } |
| 762 | |
| 763 | TEST_F(WebRtcVideoChannel2Test, DISABLED_DISABLED_SendReceiveBitratesStats) { |
| 764 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 765 | } |
| 766 | |
| 767 | TEST_F(WebRtcVideoChannel2Test, DISABLED_TestSetAdaptInputToCpuUsage) { |
| 768 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 769 | } |
| 770 | |
| 771 | TEST_F(WebRtcVideoChannel2Test, DISABLED_TestSetCpuThreshold) { |
| 772 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 773 | } |
| 774 | |
| 775 | TEST_F(WebRtcVideoChannel2Test, DISABLED_TestSetInvalidCpuThreshold) { |
| 776 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 777 | } |
| 778 | |
| 779 | TEST_F(WebRtcVideoChannel2Test, DISABLED_WebRtcShouldLog) { |
| 780 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 781 | } |
| 782 | |
| 783 | TEST_F(WebRtcVideoChannel2Test, DISABLED_WebRtcShouldNotLog) { |
| 784 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 785 | } |
| 786 | |
| 787 | TEST_F(WebRtcVideoEngine2Test, FindCodec) { |
| 788 | const std::vector<cricket::VideoCodec>& c = engine_.codecs(); |
| 789 | EXPECT_EQ(4U, c.size()); |
| 790 | |
| 791 | cricket::VideoCodec vp8(104, "VP8", 320, 200, 30, 0); |
| 792 | EXPECT_TRUE(engine_.FindCodec(vp8)); |
| 793 | |
| 794 | cricket::VideoCodec vp8_ci(104, "vp8", 320, 200, 30, 0); |
| 795 | EXPECT_TRUE(engine_.FindCodec(vp8)); |
| 796 | |
| 797 | cricket::VideoCodec vp8_diff_fr_diff_pref(104, "VP8", 320, 200, 50, 50); |
| 798 | EXPECT_TRUE(engine_.FindCodec(vp8_diff_fr_diff_pref)); |
| 799 | |
| 800 | cricket::VideoCodec vp8_diff_id(95, "VP8", 320, 200, 30, 0); |
| 801 | EXPECT_FALSE(engine_.FindCodec(vp8_diff_id)); |
| 802 | vp8_diff_id.id = 97; |
| 803 | EXPECT_TRUE(engine_.FindCodec(vp8_diff_id)); |
| 804 | |
| 805 | cricket::VideoCodec vp8_diff_res(104, "VP8", 320, 111, 30, 0); |
| 806 | EXPECT_FALSE(engine_.FindCodec(vp8_diff_res)); |
| 807 | |
| 808 | // PeerConnection doesn't negotiate the resolution at this point. |
| 809 | // Test that FindCodec can handle the case when width/height is 0. |
| 810 | cricket::VideoCodec vp8_zero_res(104, "VP8", 0, 0, 30, 0); |
| 811 | EXPECT_TRUE(engine_.FindCodec(vp8_zero_res)); |
| 812 | |
| 813 | cricket::VideoCodec red(101, "RED", 0, 0, 30, 0); |
| 814 | EXPECT_TRUE(engine_.FindCodec(red)); |
| 815 | |
| 816 | cricket::VideoCodec red_ci(101, "red", 0, 0, 30, 0); |
| 817 | EXPECT_TRUE(engine_.FindCodec(red)); |
| 818 | |
| 819 | cricket::VideoCodec fec(102, "ULPFEC", 0, 0, 30, 0); |
| 820 | EXPECT_TRUE(engine_.FindCodec(fec)); |
| 821 | |
| 822 | cricket::VideoCodec fec_ci(102, "ulpfec", 0, 0, 30, 0); |
| 823 | EXPECT_TRUE(engine_.FindCodec(fec)); |
| 824 | |
| 825 | cricket::VideoCodec rtx(96, "rtx", 0, 0, 30, 0); |
| 826 | EXPECT_TRUE(engine_.FindCodec(rtx)); |
| 827 | } |
| 828 | |
| 829 | TEST_F(WebRtcVideoEngine2Test, DefaultRtxCodecHasAssociatedPayloadTypeSet) { |
| 830 | for (size_t i = 0; i < engine_codecs_.size(); ++i) { |
| 831 | if (engine_codecs_[i].name != kRtxCodecName) |
| 832 | continue; |
| 833 | int associated_payload_type; |
| 834 | EXPECT_TRUE(engine_codecs_[i].GetParam(kCodecParamAssociatedPayloadType, |
| 835 | &associated_payload_type)); |
| 836 | EXPECT_EQ(default_codec_.id, associated_payload_type); |
| 837 | return; |
| 838 | } |
| 839 | FAIL() << "No RTX codec found among default codecs."; |
| 840 | } |
| 841 | |
| 842 | TEST_F(WebRtcVideoChannel2Test, SetDefaultSendCodecs) { |
| 843 | ASSERT_TRUE(channel_->SetSendCodecs(engine_codecs_)); |
| 844 | |
| 845 | VideoCodec codec; |
| 846 | EXPECT_TRUE(channel_->GetSendCodec(&codec)); |
| 847 | EXPECT_TRUE(codec.Matches(engine_codecs_[0])); |
| 848 | |
| 849 | // Using a RTX setup to verify that the default RTX payload type is good. |
| 850 | const std::vector<uint32> ssrcs = MAKE_VECTOR(kSsrcs1); |
| 851 | const std::vector<uint32> rtx_ssrcs = MAKE_VECTOR(kRtxSsrcs1); |
| 852 | FakeVideoSendStream* stream = AddSendStream( |
| 853 | cricket::CreateSimWithRtxStreamParams("cname", ssrcs, rtx_ssrcs)); |
| 854 | webrtc::VideoSendStream::Config config = stream->GetConfig(); |
| 855 | // TODO(pbos): Replace ExpectEqualCodecs. |
| 856 | // ExpectEqualCodecs(engine_codecs_[0], config.codec); |
| 857 | |
| 858 | // Make sure NACK and FEC are enabled on the correct payload types. |
| 859 | EXPECT_EQ(1000, config.rtp.nack.rtp_history_ms); |
| 860 | EXPECT_EQ(default_ulpfec_codec_.id, config.rtp.fec.ulpfec_payload_type); |
| 861 | EXPECT_EQ(default_red_codec_.id, config.rtp.fec.red_payload_type); |
| 862 | // TODO(pbos): Verify that the rtx ssrc is set, correct, not taken by anything |
| 863 | // else. |
| 864 | // ASSERT_EQ(1u, config.rtp.rtx.ssrcs.size()); |
| 865 | EXPECT_EQ(static_cast<int>(default_rtx_codec_.id), |
| 866 | config.rtp.rtx.payload_type); |
| 867 | // TODO(juberti): Check RTCP, PLI, TMMBR. |
| 868 | } |
| 869 | |
| 870 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsWithoutFec) { |
| 871 | std::vector<VideoCodec> codecs; |
| 872 | codecs.push_back(kVp8Codec); |
| 873 | ASSERT_TRUE(channel_->SetSendCodecs(codecs)); |
| 874 | |
| 875 | FakeVideoSendStream* stream = AddSendStream(); |
| 876 | webrtc::VideoSendStream::Config config = stream->GetConfig(); |
| 877 | |
| 878 | EXPECT_EQ(-1, config.rtp.fec.ulpfec_payload_type); |
| 879 | EXPECT_EQ(-1, config.rtp.fec.red_payload_type); |
| 880 | } |
| 881 | |
| 882 | TEST_F(WebRtcVideoChannel2Test, |
| 883 | DISABLED_SetSendCodecRejectsRtxWithoutAssociatedPayloadType) { |
| 884 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 885 | } |
| 886 | |
| 887 | TEST_F(WebRtcVideoChannel2Test, |
| 888 | DISABLED_SetSendCodecRejectsRtxWithoutMatchingVideoCodec) { |
| 889 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 890 | } |
| 891 | |
| 892 | TEST_F(WebRtcVideoChannel2Test, |
| 893 | DISABLED_SetCodecsWithoutFecDisablesCurrentFec) { |
| 894 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 895 | } |
| 896 | |
| 897 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetSendCodecsChangesExistingStreams) { |
| 898 | FAIL(); // TODO(pbos): Implement, make sure that it's changing running |
| 899 | // streams. Should it? |
| 900 | } |
| 901 | |
| 902 | TEST_F(WebRtcVideoChannel2Test, |
| 903 | DISABLED_ConstrainsSetCodecsAccordingToEncoderConfig) { |
| 904 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 905 | } |
| 906 | |
| 907 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsWithMinMaxBitrate) { |
| 908 | SetSendCodecsShouldWorkForBitrates("10", "20"); |
| 909 | } |
| 910 | |
| 911 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsRejectsMaxLessThanMinBitrate) { |
| 912 | engine_codecs_[0].params[kCodecParamMinBitrate] = "30"; |
| 913 | engine_codecs_[0].params[kCodecParamMaxBitrate] = "20"; |
| 914 | EXPECT_FALSE(channel_->SetSendCodecs(engine_codecs_)); |
| 915 | } |
| 916 | |
| 917 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsAcceptLargeMinMaxBitrate) { |
| 918 | SetSendCodecsShouldWorkForBitrates("1000", "2000"); |
| 919 | } |
| 920 | |
| 921 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsWithMaxQuantization) { |
| 922 | static const char* kMaxQuantization = "21"; |
| 923 | std::vector<VideoCodec> codecs; |
| 924 | codecs.push_back(kVp8Codec); |
| 925 | codecs[0].params[kCodecParamMaxQuantization] = kMaxQuantization; |
| 926 | EXPECT_TRUE(channel_->SetSendCodecs(codecs)); |
pbos@webrtc.org | 7254487 | 2014-06-06 10:49:19 +0000 | [diff] [blame^] | 927 | EXPECT_EQ(static_cast<unsigned int>(atoi(kMaxQuantization)), |
| 928 | AddSendStream()->GetVideoStreams().back().max_qp); |
pbos@webrtc.org | 87e1f97 | 2014-05-13 11:07:01 +0000 | [diff] [blame] | 929 | |
| 930 | VideoCodec codec; |
| 931 | EXPECT_TRUE(channel_->GetSendCodec(&codec)); |
| 932 | EXPECT_EQ(kMaxQuantization, codec.params[kCodecParamMaxQuantization]); |
| 933 | } |
| 934 | |
| 935 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsRejectBadDimensions) { |
| 936 | std::vector<cricket::VideoCodec> codecs; |
| 937 | codecs.push_back(kVp8Codec); |
| 938 | |
| 939 | codecs[0].width = 0; |
| 940 | EXPECT_FALSE(channel_->SetSendCodecs(codecs)) |
| 941 | << "Codec set though codec width is zero."; |
| 942 | |
| 943 | codecs[0].width = kVp8Codec.width; |
| 944 | codecs[0].height = 0; |
| 945 | EXPECT_FALSE(channel_->SetSendCodecs(codecs)) |
| 946 | << "Codec set though codec height is zero."; |
| 947 | } |
| 948 | |
| 949 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsRejectBadPayloadTypes) { |
| 950 | // TODO(pbos): Should we only allow the dynamic range? |
| 951 | static const size_t kNumIncorrectPayloads = 4; |
| 952 | static const int kIncorrectPayloads[kNumIncorrectPayloads] = {-2, -1, 128, |
| 953 | 129}; |
| 954 | std::vector<cricket::VideoCodec> codecs; |
| 955 | codecs.push_back(kVp8Codec); |
| 956 | for (size_t i = 0; i < kNumIncorrectPayloads; ++i) { |
| 957 | int payload_type = kIncorrectPayloads[i]; |
| 958 | codecs[0].id = payload_type; |
| 959 | EXPECT_FALSE(channel_->SetSendCodecs(codecs)) |
| 960 | << "Bad payload type '" << payload_type << "' accepted."; |
| 961 | } |
| 962 | } |
| 963 | |
| 964 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsAcceptAllValidPayloadTypes) { |
| 965 | std::vector<cricket::VideoCodec> codecs; |
| 966 | codecs.push_back(kVp8Codec); |
| 967 | for (int payload_type = 0; payload_type <= 127; ++payload_type) { |
| 968 | codecs[0].id = payload_type; |
| 969 | EXPECT_TRUE(channel_->SetSendCodecs(codecs)) |
| 970 | << "Payload type '" << payload_type << "' rejected."; |
| 971 | } |
| 972 | } |
| 973 | |
| 974 | TEST_F(WebRtcVideoChannel2Test, DISABLED_ResetVieSendCodecOnNewFrameSize) { |
| 975 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 976 | } |
| 977 | |
| 978 | TEST_F(WebRtcVideoChannel2Test, SetRecvCodecsWithOnlyVp8) { |
| 979 | std::vector<cricket::VideoCodec> codecs; |
| 980 | codecs.push_back(kVp8Codec); |
| 981 | EXPECT_TRUE(channel_->SetRecvCodecs(codecs)); |
| 982 | } |
| 983 | |
| 984 | TEST_F(WebRtcVideoChannel2Test, SetRecvCodecsDifferentPayloadType) { |
| 985 | std::vector<cricket::VideoCodec> codecs; |
| 986 | codecs.push_back(kVp8Codec); |
| 987 | codecs[0].id = 99; |
| 988 | EXPECT_TRUE(channel_->SetRecvCodecs(codecs)); |
| 989 | } |
| 990 | |
| 991 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetRecvCodecsAcceptDefaultCodecs) { |
| 992 | EXPECT_TRUE(channel_->SetRecvCodecs(engine_.codecs())); |
| 993 | // (I've added this one.) Make sure they propagate down to VideoReceiveStream! |
| 994 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 995 | } |
| 996 | |
| 997 | TEST_F(WebRtcVideoChannel2Test, SetRecvCodecsRejectUnsupportedCodec) { |
| 998 | std::vector<VideoCodec> codecs; |
| 999 | codecs.push_back(kVp8Codec); |
| 1000 | codecs.push_back(VideoCodec(101, "WTF3", 640, 400, 30, 0)); |
| 1001 | EXPECT_FALSE(channel_->SetRecvCodecs(codecs)); |
| 1002 | } |
| 1003 | |
| 1004 | // TODO(pbos): Enable VP9 through external codec support |
| 1005 | TEST_F(WebRtcVideoChannel2Test, |
| 1006 | DISABLED_SetRecvCodecsAcceptsMultipleVideoCodecs) { |
| 1007 | std::vector<VideoCodec> codecs; |
| 1008 | codecs.push_back(kVp8Codec); |
| 1009 | codecs.push_back(kVp9Codec); |
| 1010 | EXPECT_TRUE(channel_->SetRecvCodecs(codecs)); |
| 1011 | } |
| 1012 | |
| 1013 | TEST_F(WebRtcVideoChannel2Test, |
| 1014 | DISABLED_SetRecvCodecsSetsFecForAllVideoCodecs) { |
| 1015 | std::vector<VideoCodec> codecs; |
| 1016 | codecs.push_back(kVp8Codec); |
| 1017 | codecs.push_back(kVp9Codec); |
| 1018 | EXPECT_TRUE(channel_->SetRecvCodecs(codecs)); |
| 1019 | FAIL(); // TODO(pbos): Verify that the FEC parameters are set for all codecs. |
| 1020 | } |
| 1021 | |
| 1022 | TEST_F(WebRtcVideoChannel2Test, SetSendCodecsRejectDuplicateFecPayloads) { |
| 1023 | std::vector<VideoCodec> codecs; |
| 1024 | codecs.push_back(kVp8Codec); |
| 1025 | codecs.push_back(kRedCodec); |
| 1026 | codecs[1].id = codecs[0].id; |
| 1027 | EXPECT_FALSE(channel_->SetRecvCodecs(codecs)); |
| 1028 | } |
| 1029 | |
| 1030 | TEST_F(WebRtcVideoChannel2Test, SetRecvCodecsRejectDuplicateCodecPayloads) { |
| 1031 | std::vector<VideoCodec> codecs; |
| 1032 | codecs.push_back(kVp8Codec); |
| 1033 | codecs.push_back(kVp9Codec); |
| 1034 | codecs[1].id = codecs[0].id; |
| 1035 | EXPECT_FALSE(channel_->SetRecvCodecs(codecs)); |
| 1036 | } |
| 1037 | |
| 1038 | TEST_F(WebRtcVideoChannel2Test, |
| 1039 | SetRecvCodecsAcceptSameCodecOnMultiplePayloadTypes) { |
| 1040 | std::vector<VideoCodec> codecs; |
| 1041 | codecs.push_back(kVp8Codec); |
| 1042 | codecs.push_back(kVp8Codec); |
| 1043 | codecs[1].id += 1; |
| 1044 | EXPECT_TRUE(channel_->SetRecvCodecs(codecs)); |
| 1045 | } |
| 1046 | |
| 1047 | TEST_F(WebRtcVideoChannel2Test, SendStreamNotSendingByDefault) { |
| 1048 | EXPECT_FALSE(AddSendStream()->IsSending()); |
| 1049 | } |
| 1050 | |
| 1051 | TEST_F(WebRtcVideoChannel2Test, DISABLED_ReceiveStreamReceivingByDefault) { |
| 1052 | // Is this test correct though? Auto-receive? Enable receive on first packet? |
| 1053 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1054 | } |
| 1055 | |
| 1056 | TEST_F(WebRtcVideoChannel2Test, SetSend) { |
| 1057 | AddSendStream(); |
| 1058 | EXPECT_FALSE(channel_->SetSend(true)) |
| 1059 | << "Channel should not start without codecs."; |
| 1060 | EXPECT_TRUE(channel_->SetSend(false)) |
| 1061 | << "Channel should be stoppable even without set codecs."; |
| 1062 | |
| 1063 | std::vector<cricket::VideoCodec> codecs; |
| 1064 | codecs.push_back(kVp8Codec); |
| 1065 | channel_->SetSendCodecs(codecs); |
| 1066 | std::vector<FakeVideoSendStream*> streams = GetFakeSendStreams(); |
| 1067 | ASSERT_EQ(1u, streams.size()); |
| 1068 | FakeVideoSendStream* stream = streams.back(); |
| 1069 | |
| 1070 | EXPECT_FALSE(stream->IsSending()); |
| 1071 | |
| 1072 | // false->true |
| 1073 | EXPECT_TRUE(channel_->SetSend(true)); |
| 1074 | EXPECT_TRUE(stream->IsSending()); |
| 1075 | // true->true |
| 1076 | EXPECT_TRUE(channel_->SetSend(true)); |
| 1077 | EXPECT_TRUE(stream->IsSending()); |
| 1078 | // true->false |
| 1079 | EXPECT_TRUE(channel_->SetSend(false)); |
| 1080 | EXPECT_FALSE(stream->IsSending()); |
| 1081 | // false->false |
| 1082 | EXPECT_TRUE(channel_->SetSend(false)); |
| 1083 | EXPECT_FALSE(stream->IsSending()); |
| 1084 | |
| 1085 | EXPECT_TRUE(channel_->SetSend(true)); |
| 1086 | FakeVideoSendStream* new_stream = AddSendStream(); |
| 1087 | EXPECT_TRUE(new_stream->IsSending()) |
| 1088 | << "Send stream created after SetSend(true) not sending initially."; |
| 1089 | } |
| 1090 | |
| 1091 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SendAndReceiveVp8Vga) { |
| 1092 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1093 | } |
| 1094 | |
| 1095 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SendAndReceiveVp8Qvga) { |
| 1096 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1097 | } |
| 1098 | |
| 1099 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SendAndReceiveH264SvcQqvga) { |
| 1100 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1101 | } |
| 1102 | |
| 1103 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SendManyResizeOnce) { |
| 1104 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1105 | } |
| 1106 | |
| 1107 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SendVp8HdAndReceiveAdaptedVp8Vga) { |
| 1108 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1109 | } |
| 1110 | |
| 1111 | TEST_F(WebRtcVideoChannel2Test, DISABLED_TestSetDscpOptions) { |
| 1112 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1113 | } |
| 1114 | |
| 1115 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetOptionsWithMaxBitrate) { |
| 1116 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1117 | } |
| 1118 | |
| 1119 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetOptionsWithLoweredBitrate) { |
| 1120 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1121 | } |
| 1122 | |
| 1123 | TEST_F(WebRtcVideoChannel2Test, DISABLED_SetOptionsSucceedsWhenSending) { |
| 1124 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1125 | } |
| 1126 | |
| 1127 | TEST_F(WebRtcVideoChannel2Test, DISABLED_ResetCodecOnScreencast) { |
| 1128 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1129 | } |
| 1130 | |
| 1131 | TEST_F(WebRtcVideoChannel2Test, DISABLED_DontResetCodecOnSendFrame) { |
| 1132 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1133 | } |
| 1134 | |
| 1135 | TEST_F(WebRtcVideoChannel2Test, |
| 1136 | DISABLED_DontRegisterDecoderIfFactoryIsNotGiven) { |
| 1137 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1138 | } |
| 1139 | |
| 1140 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RegisterDecoderIfFactoryIsGiven) { |
| 1141 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1142 | } |
| 1143 | |
| 1144 | TEST_F(WebRtcVideoChannel2Test, DISABLED_DontRegisterDecoderMultipleTimes) { |
| 1145 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1146 | } |
| 1147 | |
| 1148 | TEST_F(WebRtcVideoChannel2Test, DISABLED_DontRegisterDecoderForNonVP8) { |
| 1149 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1150 | } |
| 1151 | |
| 1152 | TEST_F(WebRtcVideoChannel2Test, |
| 1153 | DISABLED_DontRegisterEncoderIfFactoryIsNotGiven) { |
| 1154 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1155 | } |
| 1156 | |
| 1157 | TEST_F(WebRtcVideoChannel2Test, DISABLED_RegisterEncoderIfFactoryIsGiven) { |
| 1158 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1159 | } |
| 1160 | |
| 1161 | TEST_F(WebRtcVideoChannel2Test, DISABLED_DontRegisterEncoderMultipleTimes) { |
| 1162 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1163 | } |
| 1164 | |
| 1165 | TEST_F(WebRtcVideoChannel2Test, |
| 1166 | DISABLED_RegisterEncoderWithMultipleSendStreams) { |
| 1167 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1168 | } |
| 1169 | |
| 1170 | TEST_F(WebRtcVideoChannel2Test, DISABLED_DontRegisterEncoderForNonVP8) { |
| 1171 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1172 | } |
| 1173 | |
| 1174 | TEST_F(WebRtcVideoChannel2Test, DISABLED_FeedbackParamsForNonVP8) { |
| 1175 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1176 | } |
| 1177 | |
| 1178 | TEST_F(WebRtcVideoChannel2Test, DISABLED_ExternalCodecAddedToTheEnd) { |
| 1179 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1180 | } |
| 1181 | |
| 1182 | TEST_F(WebRtcVideoChannel2Test, DISABLED_ExternalCodecIgnored) { |
| 1183 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1184 | } |
| 1185 | |
| 1186 | TEST_F(WebRtcVideoChannel2Test, DISABLED_UpdateEncoderCodecsAfterSetFactory) { |
| 1187 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1188 | } |
| 1189 | |
| 1190 | TEST_F(WebRtcVideoChannel2Test, DISABLED_OnReadyToSend) { |
| 1191 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1192 | } |
| 1193 | |
| 1194 | TEST_F(WebRtcVideoChannel2Test, DISABLED_CaptureFrameTimestampToNtpTimestamp) { |
| 1195 | FAIL() << "Not implemented."; // TODO(pbos): Implement. |
| 1196 | } |
| 1197 | } // namespace cricket |