#include "remoting/host/file_transfer/rtc_log_file_operations.h"
#include "base/memory/raw_ptr.h"
#include "base/test/task_environment.h"
#include "remoting/protocol/fake_connection_to_client.h"
#include "remoting/protocol/session.h"
#include "remoting/protocol/webrtc_event_log_data.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace remoting {
namespace {
std::string ToString(const std::vector<std::uint8_t>& data) { … }
class FakeConnectionWithRtcLog : public protocol::FakeConnectionToClient { … };
}
class RtcLogFileOperationsTest : public testing::Test { … };
TEST_F(RtcLogFileOperationsTest, InitialState_IsCreated) { … }
TEST_F(RtcLogFileOperationsTest, NonWebrtcConnection_RaisesProtocolError) { … }
TEST_F(RtcLogFileOperationsTest, EmptyLog_ZeroBytesSent) { … }
TEST_F(RtcLogFileOperationsTest, FileSizeOfMultipleLogSections_IsCorrect) { … }
TEST_F(RtcLogFileOperationsTest, PartialTransfer_IsReady) { … }
TEST_F(RtcLogFileOperationsTest, CompleteTransfer_IsComplete) { … }
TEST_F(RtcLogFileOperationsTest,
MultipleReadsOverMultipleSections_CorrectDataIsSent) { … }
}