chromium/chrome/common/safe_browsing/ipc_protobuf_message_unittest.cc

// Copyright 2015 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "chrome/common/safe_browsing/ipc_protobuf_message_test.pb.h"
#include "ipc/ipc_message.h"
#include "testing/gtest/include/gtest/gtest.h"

#define IPC_MESSAGE_IMPL
#undef CHROME_COMMON_SAFE_BROWSING_IPC_PROTOBUF_MESSAGE_TEST_MESSAGES_H_
#include "chrome/common/safe_browsing/ipc_protobuf_message_test_messages.h"

// Generate ipc protobuf traits write methods.
#include "chrome/common/safe_browsing/protobuf_message_write_macros.h"
namespace IPC {
#undef CHROME_COMMON_SAFE_BROWSING_IPC_PROTOBUF_MESSAGE_TEST_MESSAGES_H_
#include "chrome/common/safe_browsing/ipc_protobuf_message_test_messages.h"
}  // namespace IPC

// Generate ipc protobuf traits read methods.
#include "chrome/common/safe_browsing/protobuf_message_read_macros.h"
namespace IPC {
#undef CHROME_COMMON_SAFE_BROWSING_IPC_PROTOBUF_MESSAGE_TEST_MESSAGES_H_
#include "chrome/common/safe_browsing/ipc_protobuf_message_test_messages.h"
}  // namespace IPC

// Generate ipc protobuf traits log methods.
#include "chrome/common/safe_browsing/protobuf_message_log_macros.h"
namespace IPC {
#undef CHROME_COMMON_SAFE_BROWSING_IPC_PROTOBUF_MESSAGE_TEST_MESSAGES_H_
#include "chrome/common/safe_browsing/ipc_protobuf_message_test_messages.h"
}  // namespace IPC

class IPCProtobufMessageTest : public ::testing::TestWithParam<bool> {};

// Tests writing and reading a message with an optional fundamental field.
TEST_P(IPCProtobufMessageTest, FundamentalField) {}

// Tests writing and reading a message with an optional string field.
TEST_P(IPCProtobufMessageTest, StringField) {}

// Tests writing and reading a message with an optional bytes field.
TEST_P(IPCProtobufMessageTest, BytesField) {}

// Tests writing and reading a message with an optional submessage field.
TEST_P(IPCProtobufMessageTest, OptionalSubmessage) {}

// Tests writing and reading a message with a repeated submessage field.
TEST_P(IPCProtobufMessageTest, RepeatedSubmessage) {}

INSTANTIATE_TEST_SUITE_P();