chromium/chrome/browser/ui/views/incognito_clear_browsing_data_dialog_browsertest.cc

// Copyright 2021 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/views/incognito_clear_browsing_data_dialog.h"

#include "base/memory/raw_ptr.h"
#include "base/run_loop.h"
#include "base/test/bind.h"
#include "base/test/metrics/histogram_tester.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_list.h"
#include "chrome/browser/ui/test/test_browser_dialog.h"
#include "chrome/browser/ui/views/frame/browser_view.h"
#include "chrome/browser/ui/views/frame/toolbar_button_provider.h"
#include "chrome/browser/ui/views/incognito_clear_browsing_data_dialog_coordinator.h"
#include "chrome/browser/ui/views/profiles/avatar_toolbar_button.h"
#include "chrome/browser/ui/views/toolbar/toolbar_view.h"
#include "chrome/common/chrome_features.h"
#include "chrome/test/base/in_process_browser_test.h"
#include "chrome/test/base/ui_test_utils.h"
#include "content/public/test/browser_test.h"
#include "ui/base/mojom/dialog_button.mojom.h"
#include "ui/views/controls/button/label_button.h"
#include "ui/views/test/widget_test.h"
#include "ui/views/widget/widget_observer.h"

namespace {

class IncognitoClearBrowsingDataDialogTest : public InProcessBrowserTest {};

// Used to test that the bubble widget is destroyed before the browser.
class BubbleWidgetDestroyedObserver : public views::WidgetObserver {};

}  // namespace

class IncognitoClearBrowsingDataDialogBrowserTest
    : public SupportsTestDialog<IncognitoClearBrowsingDataDialogTest> {};

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogBrowserTest,
                       InvokeUi_default) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest,
                       TestDialogIsShown_DefaultBubble) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest,
                       TestCloseWindowsButton) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest, TestCancelButton) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest,
                       TestBrowserCloseEventClosesDialogFirst) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest,
                       ClearBrowsingDataNavigationInIncognito) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest,
                       TestDialogIsShown_HistoryDisclaimerBubble) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest,
                       TestCloseIncognitoButton) {}

IN_PROC_BROWSER_TEST_F(IncognitoClearBrowsingDataDialogTest, TestGotItButton) {}