chromium/mojo/public/cpp/bindings/tests/struct_unittest.cc

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

#include <stddef.h>
#include <stdint.h>
#include <string.h>
#include <utility>

#include "mojo/public/cpp/bindings/lib/message_fragment.h"
#include "mojo/public/cpp/system/message_pipe.h"
#include "mojo/public/interfaces/bindings/tests/test_export2.mojom.h"
#include "mojo/public/interfaces/bindings/tests/test_structs.mojom.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace mojo {
namespace test {
namespace {

RectPtr MakeRect(int32_t factor = 1) {}

void CheckRect(const Rect& rect, int32_t factor = 1) {}

template <typename StructType>
struct SerializeStructHelperTraits {};

template <>
struct SerializeStructHelperTraits<native::NativeStruct> {
  using DataView = native::NativeStructDataView;
};

template <typename InputType, typename DataType>
size_t SerializeStruct(InputType& input,
                       mojo::Message* message,
                       DataType** out_data) {}

MultiVersionStructPtr MakeMultiVersionStruct() {}

template <typename U, typename T>
U SerializeAndDeserialize(T input) {}

StructTest;

}  // namespace

TEST_F(StructTest, Rect) {}

TEST_F(StructTest, Clone) {}

// Serialization test of a struct with no pointer or handle members.
TEST_F(StructTest, Serialization_Basic) {}

// Construction of a struct with struct pointers from null.
TEST_F(StructTest, Construction_StructPointers) {}

// Serialization test of a struct with struct pointers.
TEST_F(StructTest, Serialization_StructPointers) {}

// Serialization test of a struct with an array member.
TEST_F(StructTest, Serialization_ArrayPointers) {}

// Serialization test of a struct with null array pointers.
TEST_F(StructTest, Serialization_NullArrayPointers) {}

// Tests deserializing structs as a newer version.
TEST_F(StructTest, Versioning_OldToNew) {}

// Tests deserializing structs as an older version.
TEST_F(StructTest, Versioning_NewToOld) {}

// Serialization test for native struct.
TEST_F(StructTest, Serialization_NativeStruct) {}

TEST_F(StructTest, Serialization_PublicAPI) {}

TEST_F(StructTest, VersionedStructConstructor) {}

TEST_F(StructTest, EnumNestedStructTest) {}

TEST_F(StructTest, Matcher) {}

}  // namespace test
}  // namespace mojo