#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "remoting/protocol/message_decoder.h"
#include <stdint.h>
#include <list>
#include <memory>
#include <string>
#include "base/strings/string_number_conversions.h"
#include "remoting/proto/event.pb.h"
#include "remoting/proto/internal.pb.h"
#include "remoting/protocol/message_serialization.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace remoting::protocol {
static const unsigned int kTestKey = …;
static void AppendMessage(const EventMessage& msg, std::string* buffer) { … }
static void PrepareData(uint8_t** buffer, int* size) { … }
void SimulateReadSequence(const int read_sequence[], int sequence_size) { … }
TEST(MessageDecoderTest, SmallReads) { … }
TEST(MessageDecoderTest, LargeReads) { … }
TEST(MessageDecoderTest, EmptyReads) { … }
}