#include "remoting/protocol/video_frame_pump.h"
#include <memory>
#include <utility>
#include "base/functional/bind.h"
#include "base/memory/ptr_util.h"
#include "base/memory/raw_ptr.h"
#include "base/run_loop.h"
#include "base/task/single_thread_task_runner.h"
#include "base/test/task_environment.h"
#include "remoting/base/auto_thread.h"
#include "remoting/base/auto_thread_task_runner.h"
#include "remoting/codec/video_encoder.h"
#include "remoting/codec/video_encoder_verbatim.h"
#include "remoting/proto/control.pb.h"
#include "remoting/proto/video.pb.h"
#include "remoting/protocol/desktop_capturer.h"
#include "remoting/protocol/fake_desktop_capturer.h"
#include "remoting/protocol/protocol_mock_objects.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/webrtc/modules/desktop_capture/desktop_frame.h"
_;
AtLeast;
DoAll;
Expectation;
InvokeWithoutArgs;
Return;
namespace remoting::protocol {
namespace {
ACTION(FinishSend) { … }
std::unique_ptr<webrtc::DesktopFrame> CreateNullFrame(
webrtc::SharedMemoryFactory* shared_memory_factory) { … }
std::unique_ptr<webrtc::DesktopFrame> CreateUnchangedFrame(
webrtc::SharedMemoryFactory* shared_memory_factory) { … }
class MockVideoEncoder : public VideoEncoder { … };
}
static const int kWidth = …;
static const int kHeight = …;
class ThreadCheckVideoEncoder : public VideoEncoderVerbatim { … };
class ThreadCheckDesktopCapturer : public DesktopCapturer { … };
class VideoFramePumpTest : public testing::Test { … };
void VideoFramePumpTest::SetUp() { … }
void VideoFramePumpTest::TearDown() { … }
TEST_F(VideoFramePumpTest, StartAndStop) { … }
TEST_F(VideoFramePumpTest, NullFrame) { … }
TEST_F(VideoFramePumpTest, UnchangedFrame) { … }
}