mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-01 22:07:41 +00:00
Bug 1697059 require favicon to be in the extension xpi r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D108270
This commit is contained in:
parent
7d11b0aa66
commit
8b91be585f
@ -49,9 +49,18 @@
|
||||
"preprocess": "localize"
|
||||
},
|
||||
"favicon_url": {
|
||||
"type": "string",
|
||||
"choices": [
|
||||
{
|
||||
"type": "string",
|
||||
"format": "relativeUrl",
|
||||
"max_manifest_version": 2
|
||||
},
|
||||
{
|
||||
"type": "string",
|
||||
"format": "strictRelativeUrl"
|
||||
}
|
||||
],
|
||||
"optional": true,
|
||||
"format": "relativeUrl",
|
||||
"preprocess": "localize"
|
||||
},
|
||||
"suggest_url": {
|
||||
|
@ -552,3 +552,32 @@ add_task(async function test_extension_allow_http_for_localhost() {
|
||||
|
||||
await ext1.unload();
|
||||
});
|
||||
|
||||
add_task(async function test_search_favicon_mv3() {
|
||||
Services.prefs.setBoolPref("extensions.manifestV3.enabled", true);
|
||||
let normalized = await ExtensionTestUtils.normalizeManifest({
|
||||
manifest_version: 3,
|
||||
chrome_settings_overrides: {
|
||||
search_provider: {
|
||||
name: "HTTP Icon in MV3",
|
||||
search_url: "https://example.org/",
|
||||
favicon_url: "https://example.org/icon.png",
|
||||
},
|
||||
},
|
||||
});
|
||||
Assert.ok(
|
||||
normalized.error.endsWith("must be a relative URL"),
|
||||
"Should have an error"
|
||||
);
|
||||
normalized = await ExtensionTestUtils.normalizeManifest({
|
||||
manifest_version: 3,
|
||||
chrome_settings_overrides: {
|
||||
search_provider: {
|
||||
name: "HTTP Icon in MV3",
|
||||
search_url: "https://example.org/",
|
||||
favicon_url: "/icon.png",
|
||||
},
|
||||
},
|
||||
});
|
||||
Assert.ok(!normalized.error, "Should not have an error");
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user