#include "base/memory/raw_ptr.h"
#include "base/run_loop.h"
#include "base/strings/string_number_conversions.h"
#include "base/test/bind.h"
#include "chrome/browser/apps/app_service/app_registry_cache_waiter.h"
#include "chrome/browser/badging/badge_manager.h"
#include "chrome/browser/badging/badge_manager_factory.h"
#include "chrome/browser/badging/test_badge_manager_delegate.h"
#include "chrome/browser/browsing_data/chrome_browsing_data_remover_constants.h"
#include "chrome/browser/browsing_data/chrome_browsing_data_remover_delegate.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/tabs/tab_strip_model.h"
#include "chrome/browser/ui/web_applications/web_app_browsertest_base.h"
#include "chrome/browser/web_applications/mojom/user_display_mode.mojom.h"
#include "chrome/browser/web_applications/test/web_app_install_test_utils.h"
#include "chrome/browser/web_applications/web_app_install_info.h"
#include "chrome/browser/web_applications/web_app_provider.h"
#include "chrome/browser/web_applications/web_app_registrar.h"
#include "content/public/browser/browsing_data_filter_builder.h"
#include "content/public/browser/web_contents.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
RenderFrameHost;
namespace web_app {
class WebAppBadgingBrowserTest : public WebAppBrowserTestBase { … };
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest,
CrossSiteFrameCannotChangeMainFrameBadge) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, BadgeCanBeSetToAnInteger) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest,
BadgeCanBeClearedWithClearMethod) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, BadgeCanBeClearedWithZero) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, BadgeCanBeSetWithoutAValue) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest,
BadgeCanBeSetAndClearedFromInScopeFrame) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, SubFrameBadgeAffectsSubApp) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, BadgeSubFrameAppViaNavigator) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, BadgeSubFrameAppViaCall) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest,
SubAppServiceWorkerBadgeAffectsSubApp) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest,
AppServiceWorkerBadgeAffectsMultipleApps) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest,
BadgingIncognitoWindowsDoesNotCrash) { … }
IN_PROC_BROWSER_TEST_F(WebAppBadgingBrowserTest, ClearLastBadgingTime) { … }
}