| Index: chrome/test/data/extensions/api_test/webstore_private/icon_url.js
|
| diff --git a/chrome/test/data/extensions/api_test/webstore_private/icon_url.js b/chrome/test/data/extensions/api_test/webstore_private/icon_url.js
|
| index 0b86916100e236b190e1748f922f24b89da35649..13f448186da23fcaaff0f2494a4c31ae2eb68ae0 100644
|
| --- a/chrome/test/data/extensions/api_test/webstore_private/icon_url.js
|
| +++ b/chrome/test/data/extensions/api_test/webstore_private/icon_url.js
|
| @@ -9,6 +9,16 @@ function makeAbsoluteUrl(path) {
|
| return parts.join("/");
|
| }
|
|
|
| +// The |absoluteIconUrl| parameter controls whether to use a relative or
|
| +// absolute url for the test.
|
| +function runSuccessTest(absoluteIconUrl, manifest) {
|
| + var iconPath = "extension/icon.png";
|
| + var iconUrl = absoluteIconUrl ? makeAbsoluteUrl(iconPath) : iconPath;
|
| + installAndCleanUp(
|
| + {'id': extensionId,'iconUrl': iconUrl, 'manifest': manifest },
|
| + function() {});
|
| +}
|
| +
|
| var tests = [
|
| function IconUrlFailure() {
|
| var manifest = getManifest();
|
| @@ -22,18 +32,12 @@ var tests = [
|
|
|
| function IconUrlSuccess() {
|
| var manifest = getManifest();
|
| + runSuccessTest(false, manifest);
|
| + },
|
|
|
| - // The |absoluteIconUrl| parameter controls whether to use a relative or
|
| - // absolute url for the test.
|
| - function runSuccessTest(absoluteIconUrl) {
|
| - var iconPath = "extension/icon.png";
|
| - var iconUrl = absoluteIconUrl ? makeAbsoluteUrl(iconPath) : iconPath;
|
| - chrome.webstorePrivate.beginInstallWithManifest3(
|
| - {'id': extensionId,'iconUrl': iconUrl, 'manifest': manifest },
|
| - callbackPass());
|
| - }
|
| - runSuccessTest(true);
|
| - runSuccessTest(false);
|
| + function IconUrlSuccessAbsoluteUrl() {
|
| + var manifest = getManifest();
|
| + runSuccessTest(true, manifest);
|
| }
|
| ];
|
|
|
|
|