Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(219)

Unified Diff: components/favicon/core/favicon_handler_unittest.cc

Issue 2958503002: Enable feature to load icons from Web Manifests by defaut (Closed)
Patch Set: Update unit tests. Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/favicon/content_favicon_driver_browsertest.cc ('k') | components/favicon/core/features.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/favicon/core/favicon_handler_unittest.cc
diff --git a/components/favicon/core/favicon_handler_unittest.cc b/components/favicon/core/favicon_handler_unittest.cc
index be6a075c14062795b666e0d8257682ce75132201..8c932e1e192b2924a69d953fa25eab59321788f8 100644
--- a/components/favicon/core/favicon_handler_unittest.cc
+++ b/components/favicon/core/favicon_handler_unittest.cc
@@ -1460,10 +1460,11 @@ TEST_F(FaviconHandlerTest, TestRecordSkippedDownloadForKnownFailingUrl) {
/*expected_count=*/1)));
}
-// Test that the support for Web Manifest is disabled by default, unless the
-// feature is enabled.
-TEST_F(FaviconHandlerTest, IgnoreWebManifestByDefault) {
+// Test that the feature for loading icons from Web Manifests can be disabled.
+TEST_F(FaviconHandlerTest, IgnoreWebManifest) {
const GURL kManifestURL("http://www.google.com/manifest.json");
+ base::test::ScopedFeatureList override_features;
+ override_features.InitAndDisableFeature(kFaviconsFromWebManifest);
RunHandlerWithSimpleFaviconCandidates({kIconURL16x16}, kManifestURL);
EXPECT_THAT(favicon_service_.fake()->db_requests(),
@@ -1471,17 +1472,15 @@ TEST_F(FaviconHandlerTest, IgnoreWebManifestByDefault) {
EXPECT_THAT(delegate_.downloads(), Not(Contains(kManifestURL)));
}
+// Manifests are currently enabled by default. Leaving this fixture for
+// logical grouping and blame layer.
class FaviconHandlerManifestsEnabledTest : public FaviconHandlerTest {
protected:
const GURL kManifestURL = GURL("http://www.google.com/manifest.json");
- FaviconHandlerManifestsEnabledTest() {
- override_features_.InitAndEnableFeature(kFaviconsFromWebManifest);
- }
+ FaviconHandlerManifestsEnabledTest() = default;
private:
- base::test::ScopedFeatureList override_features_;
-
DISALLOW_COPY_AND_ASSIGN(FaviconHandlerManifestsEnabledTest);
};
« no previous file with comments | « chrome/browser/favicon/content_favicon_driver_browsertest.cc ('k') | components/favicon/core/features.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698