diff --git a/app/brave_main_delegate_browsertest.cc b/app/brave_main_delegate_browsertest.cc index 0dff2d69b5e9..fe7f84d59774 100644 --- a/app/brave_main_delegate_browsertest.cc +++ b/app/brave_main_delegate_browsertest.cc @@ -50,6 +50,7 @@ #include "chrome/browser/ui/profile_picker.h" #include "chrome/browser/ui/ui_features.h" #include "chrome/test/base/in_process_browser_test.h" +#include "components/safe_browsing/core/common/features.h" #include "components/translate/core/common/translate_util.h" #include "extensions/common/extension_features.h" #endif @@ -215,6 +216,8 @@ IN_PROC_BROWSER_TEST_F(BraveMainDelegateBrowserTest, EnabledFeatures) { &features::kWinrtGeolocationImplementation, #endif #if !BUILDFLAG(IS_ANDROID) + &safe_browsing::kDownloadBubble, + &safe_browsing::kDownloadBubbleV2, &sharing_hub::kDesktopScreenshots, #endif &media::kEnableTabMuting, diff --git a/chromium_src/components/safe_browsing/core/common/features.cc b/chromium_src/components/safe_browsing/core/common/features.cc new file mode 100644 index 000000000000..a7bf0f6567a2 --- /dev/null +++ b/chromium_src/components/safe_browsing/core/common/features.cc @@ -0,0 +1,21 @@ +/* Copyright (c) 2023 The Brave Authors. All rights reserved. + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this file, + * You can obtain one at https://mozilla.org/MPL/2.0/. */ + +#include "src/components/safe_browsing/core/common/features.cc" + +#include "base/feature_override.h" +#include "build/build_config.h" + +namespace safe_browsing { + +// Download bubble is desktop only feature. +#if !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_IOS) +OVERRIDE_FEATURE_DEFAULT_STATES({{ + {kDownloadBubble, base::FEATURE_ENABLED_BY_DEFAULT}, + {kDownloadBubbleV2, base::FEATURE_ENABLED_BY_DEFAULT}, +}}); +#endif + +} // namespace safe_browsing diff --git a/test/filters/browser_tests.filter b/test/filters/browser_tests.filter index 5f9d103c1f95..c4dd0104ea26 100644 --- a/test/filters/browser_tests.filter +++ b/test/filters/browser_tests.filter @@ -469,6 +469,14 @@ -PdfOcrMenuObserverTest.PdfOcrItemShownWithScreenReaderEnabled -PluginInfoHostImplTest.GetPluginInfoForPdfInternalPlugin +# These tests failed because we enable download bubble features by default. +# safe_browsing::kDownloadBubble, safe_browsing::kDownloadBubbleV2 +-DownloadExtensionTest.DownloadExtensionTest_Download_Incognito +-DownloadExtensionTest.DownloadExtensionTest_OnDeterminingFilename_IncognitoSpanning +-DownloadExtensionTest.DownloadExtensionTest_OnDeterminingFilename_IncognitoSplit +-DownloadExtensionTest.DownloadExtensionTest_SearchPauseResumeCancelGetFileIconIncognito +-DownloadTestWithFakeSafeBrowsing.NoUncommonDownloadReportIfIncognito + # Tests below this point have not been diagnosed or had issues created yet. -_/WebrtcLoggingPrivateApiStartEventLoggingTestFeatureAndPolicyEnabled.* -AccessCodeCastHandlerBrowserTest.* diff --git a/test/filters/unit_tests.filter b/test/filters/unit_tests.filter index cf0dba967499..a12a1fea0a7c 100644 --- a/test/filters/unit_tests.filter +++ b/test/filters/unit_tests.filter @@ -170,6 +170,17 @@ -MediaRouterUIServiceFactoryUnitTest.* -MediaRouterViewsUITest.* +# These tests failed because we enable download bubble features by default. +# safe_browsing::kDownloadBubble, safe_browsing::kDownloadBubbleV2 +-DownloadBubbleUIControllerIncognitoTest.DoesNotShowDetailsIfDone +-DownloadBubbleUIControllerIncognitoTest.IncludeDownloadsFromMainProfile +-DownloadBubbleUIControllerTest.ListIsRecent +-DownloadBubbleUIControllerTest.ListIsSorted +-DownloadBubbleUIControllerTest.OpeningMainViewRemovesEntryFromPartialView +-DownloadBubbleUIControllerTest.ProcessesUpdatedItems +-DownloadBubbleUIControllerTest.TransientDownloadShouldNotShow +-DownloadBubbleSecurityViewTest.UpdateSecurityView_WillHaveAppropriateDialogButtons + # This test is disabled because the Brave NTP doesn't support this feature -NewTabPageModulesTest.HasModulesEnabled_SignedInAccount