chromium/chrome/browser/ui/webui/whats_new/whats_new_handler_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 "chrome/browser/ui/webui/whats_new/whats_new_handler.h"

#include "base/test/metrics/histogram_tester.h"
#include "base/test/metrics/user_action_tester.h"
#include "base/test/mock_callback.h"
#include "base/test/scoped_feature_list.h"
#include "chrome/browser/ui/hats/hats_service_factory.h"
#include "chrome/browser/ui/hats/mock_hats_service.h"
#include "chrome/browser/ui/webui/whats_new/whats_new.mojom.h"
#include "chrome/browser/ui/webui/whats_new/whats_new_ui.h"
#include "chrome/browser/ui/webui/whats_new/whats_new_util.h"
#include "chrome/common/chrome_features.h"
#include "chrome/common/chrome_version.h"
#include "chrome/common/pref_names.h"
#include "chrome/test/base/scoped_testing_local_state.h"
#include "chrome/test/base/testing_browser_process.h"
#include "chrome/test/base/testing_profile.h"
#include "components/user_education/common/user_education_features.h"
#include "content/public/test/browser_task_environment.h"
#include "content/public/test/test_web_contents_factory.h"
#include "mojo/public/cpp/bindings/pending_receiver.h"
#include "mojo/public/cpp/bindings/pending_remote.h"
#include "mojo/public/cpp/bindings/receiver.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace {

class MockPage : public whats_new::mojom::Page {};

}  // namespace

class WhatsNewHandlerTest : public testing::Test {};

TEST_F(WhatsNewHandlerTest, GetServerUrl) {}

TEST_F(WhatsNewHandlerTest, HistogramsAreEmitted) {}

class WhatsNewHandlerTestWithCountry
    : public WhatsNewHandlerTest,
      public testing::WithParamInterface<absl::string_view> {};

TEST_P(WhatsNewHandlerTestWithCountry, SurveyIsTriggeredInActiveCountries) {}

TEST_P(WhatsNewHandlerTestWithCountry,
       AlternateSurveyIsTriggeredInActiveCountries) {}

constexpr std::string_view test_countries[] =;
INSTANTIATE_TEST_SUITE_P();