chromium/components/plus_addresses/webdata/plus_address_table_unittest.cc

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

#include "components/plus_addresses/webdata/plus_address_table.h"

#include <optional>

#include "base/files/scoped_temp_dir.h"
#include "components/plus_addresses/plus_address_test_utils.h"
#include "components/plus_addresses/plus_address_types.h"
#include "components/sync/base/data_type.h"
#include "components/sync/model/metadata_batch.h"
#include "components/sync/protocol/data_type_state.pb.h"
#include "components/sync/protocol/entity_metadata.pb.h"
#include "components/webdata/common/web_database.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace plus_addresses {

namespace {

// Matches a std::pair<std::string, std::unique_ptr<some-proto>> against a given
// (std::string key, (some-proto) value) pair, comparing protos as strings.
MATCHER_P2(KeyAndProto, key, value, "") {}

class PlusAddressTableTest : public testing::Test {};

TEST_F(PlusAddressTableTest, GetPlusProfiles) {}

TEST_F(PlusAddressTableTest, GetPlusProfileForId) {}

TEST_F(PlusAddressTableTest, AddOrUpdatePlusProfile) {}

TEST_F(PlusAddressTableTest, RemovePlusProfile) {}

TEST_F(PlusAddressTableTest, ClearPlusProfiles) {}

// Tests that when no sync metadata is persisted, `GetAllSyncMetadata()` returns
// the default data type state without any entity metadata.
TEST_F(PlusAddressTableTest, SyncMetadataStore_NoData) {}

// Tests adding and updating the sync data type state.
TEST_F(PlusAddressTableTest, SyncMetadataStore_ModifyDataTypeState) {}

// Tests adding and updating sync entity metadata.
TEST_F(PlusAddressTableTest, SyncMetadataStore_ModifyEntityMetadata) {}

// Tests clearing the sync data type state + entity metadata.
TEST_F(PlusAddressTableTest, SyncMetadataStore_Clear) {}

}  // namespace

}  // namespace plus_addresses