chromium/third_party/crashpad/crashpad/snapshot/crashpad_types/crashpad_info_reader_test.cc

// Copyright 2017 The Crashpad Authors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

#include "snapshot/crashpad_types/crashpad_info_reader.h"

#include <sys/types.h>

#include <memory>

#include "build/build_config.h"
#include "client/annotation_list.h"
#include "client/crashpad_info.h"
#include "client/simple_address_range_bag.h"
#include "client/simple_string_dictionary.h"
#include "gtest/gtest.h"
#include "test/multiprocess_exec.h"
#include "test/process_type.h"
#include "util/file/file_io.h"
#include "util/misc/from_pointer_cast.h"
#include "util/process/process_memory_native.h"

#if BUILDFLAG(IS_ANDROID) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
#include "test/linux/fake_ptrace_connection.h"
#endif

namespace crashpad {
namespace test {
namespace {

constexpr TriState kCrashpadHandlerBehavior =;
constexpr TriState kSystemCrashReporterForwarding =;
constexpr TriState kGatherIndirectlyReferencedMemory =;

constexpr uint32_t kIndirectlyReferencedMemoryCap =;

class ScopedUnsetCrashpadInfo {};

class CrashpadInfoTestDataSetup {};

void ExpectCrashpadInfo(ProcessType process,
                        bool is_64_bit,
                        VMAddress info_address,
                        VMAddress extra_memory_address,
                        VMAddress simple_annotations_address,
                        VMAddress annotations_list_address) {}

TEST(CrashpadInfoReader, ReadFromSelf) {}

CRASHPAD_CHILD_TEST_MAIN(ReadFromChildTestMain) {}

class ReadFromChildTest : public MultiprocessExec {};

TEST(CrashpadInfoReader, ReadFromChild) {}

}  // namespace
}  // namespace test
}  // namespace crashpad