#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "components/web_modal/web_contents_modal_dialog_manager.h"
#include <map>
#include <memory>
#include "base/memory/ptr_util.h"
#include "base/memory/raw_ptr.h"
#include "build/build_config.h"
#include "components/web_modal/single_web_contents_dialog_manager.h"
#include "components/web_modal/test_web_contents_modal_dialog_manager_delegate.h"
#include "content/public/test/test_renderer_host.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace web_modal {
class MockCloseOnNavigationObserver
: public WebContentsModalDialogManager::CloseOnNavigationObserver { … };
class NativeManagerTracker { … };
NativeManagerTracker unused_tracker;
class TestNativeWebContentsModalDialogManager
: public SingleWebContentsDialogManager { … };
class WebContentsModalDialogManagerTest
: public content::RenderViewHostTestHarness { … };
TEST_F(WebContentsModalDialogManagerTest, WebContentsVisible) { … }
TEST_F(WebContentsModalDialogManagerTest, WebContentsNotVisible) { … }
TEST_F(WebContentsModalDialogManagerTest, ShowDialogs) { … }
TEST_F(WebContentsModalDialogManagerTest, VisibilityObservation) { … }
TEST_F(WebContentsModalDialogManagerTest, OccludedToVisible) { … }
TEST_F(WebContentsModalDialogManagerTest, VisibleToOccluded) { … }
TEST_F(WebContentsModalDialogManagerTest, CloseDialogs) { … }
TEST_F(WebContentsModalDialogManagerTest, CloseAllDialogs) { … }
TEST_F(WebContentsModalDialogManagerTest, CloseOnNavigation) { … }
TEST_F(WebContentsModalDialogManagerTest,
ObserverNotNotifiedOfNonNavigationClose) { … }
}