chromium/chrome/browser/ui/views/side_panel/search_companion/companion_live_test.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 "base/feature_list.h"
#include "base/metrics/histogram_base.h"
#include "base/metrics/histogram_samples.h"
#include "base/metrics/statistics_recorder.h"
#include "base/test/bind.h"
#include "base/test/metrics/histogram_tester.h"
#include "base/test/scoped_feature_list.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/companion/core/companion_metrics_logger.h"
#include "chrome/browser/companion/core/features.h"
#include "chrome/browser/companion/core/mojom/companion.mojom.h"
#include "chrome/browser/companion/core/proto/companion_url_params.pb.h"
#include "chrome/browser/signin/e2e_tests/account_capabilities_observer.h"
#include "chrome/browser/signin/e2e_tests/accounts_removed_waiter.h"
#include "chrome/browser/signin/e2e_tests/live_test.h"
#include "chrome/browser/signin/e2e_tests/sign_in_test_observer.h"
#include "chrome/browser/signin/e2e_tests/signin_util.h"
#include "chrome/browser/signin/e2e_tests/test_accounts_util.h"
#include "chrome/browser/signin/identity_manager_factory.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_window/public/browser_window_features.h"
#include "chrome/browser/ui/views/frame/browser_view.h"
#include "chrome/browser/ui/views/side_panel/companion/companion_tab_helper.h"
#include "chrome/browser/ui/views/side_panel/search_companion/search_companion_side_panel_coordinator.h"
#include "chrome/browser/ui/views/side_panel/side_panel_coordinator.h"
#include "chrome/browser/ui/views/side_panel/side_panel_enums.h"
#include "chrome/test/base/ui_test_utils.h"
#include "components/signin/core/browser/account_reconcilor.h"
#include "components/signin/public/identity_manager/identity_manager.h"
#include "components/signin/public/identity_manager/identity_test_utils.h"
#include "components/sync/service/sync_service.h"
#include "content/public/browser/web_contents.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
#include "content/public/test/test_navigation_observer.h"
#include "net/dns/mock_host_resolver.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/compositor/scoped_animation_duration_scale_mode.h"

namespace signin::test {

namespace {
const std::string kExpsUrl("https://labs.google.com/search/experiments/");
const std::string kFailureUrl("https://labs.google.com/search/error");
const std::string kGoogleUrl("https://www.google.com/");
const std::string kLensUrl("https://lens.google.com/companion");
const std::string kNpsUrl("https://www.nps.gov/articles/route-66-overview.htm");
}  // namespace

// Live tests for Companion.
// These tests can be run with:
// browser_tests --gtest_filter=CompanionLiveTest.* --run-live-tests
class CompanionLiveTest : public signin::test::LiveTest {};

// Test will only run when passed the --run-live-tests flag. To run, use
// browser_tests --gtest_filter=CompanionLiveTest.* --run-live-tests
IN_PROC_BROWSER_TEST_F(CompanionLiveTest, InitialNavigation) {}

IN_PROC_BROWSER_TEST_F(CompanionLiveTest, InitialNavigationNotOptedIn) {}

IN_PROC_BROWSER_TEST_F(CompanionLiveTest, InitialNavigationLoggedOut) {}

IN_PROC_BROWSER_TEST_F(CompanionLiveTest, ToggleExps) {}

}  // namespace signin::test