| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2017 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2017 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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 rtc::Event init_decode_event_(false, false); | 122 rtc::Event init_decode_event_(false, false); |
| 123 EXPECT_CALL(mock_h264_video_decoder_, InitDecode(_, _)) | 123 EXPECT_CALL(mock_h264_video_decoder_, InitDecode(_, _)) |
| 124 .WillOnce(Invoke([&init_decode_event_](const VideoCodec* config, | 124 .WillOnce(Invoke([&init_decode_event_](const VideoCodec* config, |
| 125 int32_t number_of_cores) { | 125 int32_t number_of_cores) { |
| 126 init_decode_event_.Set(); | 126 init_decode_event_.Set(); |
| 127 return 0; | 127 return 0; |
| 128 })); | 128 })); |
| 129 EXPECT_CALL(mock_h264_video_decoder_, RegisterDecodeCompleteCallback(_)); | 129 EXPECT_CALL(mock_h264_video_decoder_, RegisterDecodeCompleteCallback(_)); |
| 130 video_receive_stream_->Start(); | 130 video_receive_stream_->Start(); |
| 131 EXPECT_CALL(mock_h264_video_decoder_, Decode(_, false, _, _, _)); | 131 EXPECT_CALL(mock_h264_video_decoder_, Decode(_, false, _, _, _)); |
| 132 EXPECT_EQ(true, | 132 RtpPacketReceived parsed_packet; |
| 133 video_receive_stream_->OnRecoveredPacket(rtppacket.data(), | 133 ASSERT_TRUE(parsed_packet.Parse(rtppacket.data(), rtppacket.size())); |
| 134 rtppacket.size())); | 134 video_receive_stream_->OnRtpPacket(parsed_packet); |
| 135 EXPECT_CALL(mock_h264_video_decoder_, Release()); | 135 EXPECT_CALL(mock_h264_video_decoder_, Release()); |
| 136 // Make sure the decoder thread had a chance to run. | 136 // Make sure the decoder thread had a chance to run. |
| 137 init_decode_event_.Wait(kDefaultTimeOutMs); | 137 init_decode_event_.Wait(kDefaultTimeOutMs); |
| 138 } | 138 } |
| 139 } // namespace webrtc | 139 } // namespace webrtc |
| OLD | NEW |