chromium/chrome/browser/browsing_data/chrome_browsing_data_model_delegate_unittest.cc

// Copyright 2023 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/browser/browsing_data/chrome_browsing_data_model_delegate.h"

#include <vector>

#include "base/files/scoped_temp_dir.h"
#include "base/functional/callback_helpers.h"
#include "base/test/bind.h"
#include "base/test/test_future.h"
#include "chrome/browser/browsing_data/chrome_browsing_data_remover_constants.h"
#include "chrome/browser/browsing_topics/browsing_topics_service_factory.h"
#include "chrome/browser/media/webrtc/media_device_salt_service_factory.h"
#include "chrome/browser/webid/federated_identity_permission_context.h"
#include "chrome/browser/webid/federated_identity_permission_context_factory.h"
#include "chrome/test/base/testing_browser_process.h"
#include "chrome/test/base/testing_profile.h"
#include "chrome/test/base/testing_profile_manager.h"
#include "components/browsing_topics/test_util.h"
#include "components/media_device_salt/media_device_salt_service.h"
#include "components/nacl/common/buildflags.h"
#include "content/public/browser/browsing_data_remover.h"
#include "content/public/test/browser_task_environment.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/public/common/storage_key/storage_key.h"
#include "url/gurl.h"

#if !BUILDFLAG(IS_ANDROID)
#include "chrome/browser/web_applications/web_app_command_manager.h"
#include "chrome/browser/web_applications/web_app_provider.h"
#endif

#if BUILDFLAG(ENABLE_NACL)
#include "chrome/browser/nacl_host/nacl_browser_delegate_impl.h"
#include "components/nacl/browser/nacl_browser.h"
#endif  // BUILDFLAG(ENABLE_NACL)

Contains;
ElementsAre;
UnorderedElementsAre;

namespace {

blink::StorageKey StorageKey1() {}

blink::StorageKey StorageKey2() {}

}  // namespace

#if BUILDFLAG(ENABLE_NACL)
class ScopedNaClBrowserDelegate {
 public:
  ~ScopedNaClBrowserDelegate() { nacl::NaClBrowser::ClearAndDeleteDelegate(); }

  void Init(ProfileManager* profile_manager) {
    nacl::NaClBrowser::SetDelegate(
        std::make_unique<NaClBrowserDelegateImpl>(profile_manager));
  }
};
#endif  // BUILDFLAG(ENABLE_NACL)

class ChromeBrowsingDataModelDelegateTest : public testing::Test {};

TEST_F(ChromeBrowsingDataModelDelegateTest, RemoveDataKeyForTopics) {}

TEST_F(ChromeBrowsingDataModelDelegateTest, RemoveDataKeyForMediaDeviceSalts) {}

TEST_F(ChromeBrowsingDataModelDelegateTest, GetAllDataKeysAndGetDataOwner) {}

#if !BUILDFLAG(IS_ANDROID)
TEST_F(ChromeBrowsingDataModelDelegateTest, RemoveIsolatedWebAppData) {}
#endif  // !BUILDFLAG(IS_ANDROID)

TEST_F(ChromeBrowsingDataModelDelegateTest, CookieDeletionFilterChildUser) {}

TEST_F(ChromeBrowsingDataModelDelegateTest, CookieDeletionFilterNormalUser) {}

TEST_F(ChromeBrowsingDataModelDelegateTest, CookieDeletionFilterIncognitoUser) {}

TEST_F(ChromeBrowsingDataModelDelegateTest, RemoveFederatedIdentityData) {}