Chromium Code Reviews| Index: chrome/test/data/extensions/api_test/extension_gallery_install/test.html |
| =================================================================== |
| --- chrome/test/data/extensions/api_test/extension_gallery_install/test.html (revision 65457) |
| +++ chrome/test/data/extensions/api_test/extension_gallery_install/test.html (working copy) |
| @@ -16,7 +16,7 @@ |
| if (id == extension.id) |
| found = true; |
| }); |
| - |
| + |
| callback(found); |
| }); |
| } |
| @@ -26,10 +26,10 @@ |
| chrome.test.assertEq(false, installed); |
| // Install "gallery" extensions. |
| - chrome.management.onInstalled.addListener(function(info) { |
| + chrome.management.onInstalled.addListener(function(info) { |
| chrome.test.assertEq(id, info.id); |
| console.log("Installed " + info.id); |
| - |
| + |
| // Double check it is installed. |
| checkInstalled(function(installed) { |
| chrome.test.assertEq(true, installed); |
| @@ -39,7 +39,7 @@ |
| // And check that it's gone. |
| checkInstalled(function(installed) { |
| chrome.test.assertEq(false, installed); |
| - |
| + |
| chrome.test.succeed(); |
| }); |
| }); |
| @@ -50,8 +50,17 @@ |
| }); |
| }); |
| }); |
| - chrome.webstorePrivate.install(id, function() { |
| + chrome.webstorePrivate.beginInstall(id, function() { |
| + if (window.location.href.indexOf("expect_error=true") > 0) { |
| + chrome.test.assertEq(chrome.extension.lastError.message, |
| + "This function must be called during a user gesture"); |
| + chrome.test.succeed(); |
| + return; |
| + } |
| chrome.test.assertNoLastError(); |
| + chrome.webstorePrivate.completeInstall(id, function() { |
|
Erik does not do reviews
2010/11/09 16:32:21
seems like you need a couple of tests that call co
asargent_no_longer_on_chrome
2010/11/10 00:23:48
I've simplified this test and added others to cove
|
| + chrome.test.assertNoLastError(); |
| + }); |
| }); |
| console.log("Installing..."); |
| }); |