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

Side by Side Diff: chrome/test/data/extensions/api_test/webstore_private/bundle/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.crx

Issue 855513002: Add/resurrect support for bundles of WebStore items. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@testext_bundle
Patch Set: fix BitmapFetcher destruction Created 5 years, 8 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 unified diff | Download patch
OLDNEW
(Empty)
1 <!--
2 * Copyright (c) 2012 The Chromium Authors. All rights reserved. Use of this
3 * source code is governed by a BSD-style license that can be found in the
4 * LICENSE file.
5 -->
6 <script src="common.js"></script>
7 <script>
8
9 var bundleItems = [
10 {
11 id: 'begfmnajjkbjdgmffnjaojchoncnmngg',
12 manifest: getManifest('bundle/app1.json'),
13 localizedName: 'app.1'
14 },
15 {
16 id: 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa', // Invalid CRX.
17 manifest: getManifest('bundle/app2.json'),
18 localizedName: 'app.2'
19 },
20 {
21 id: 'bmfoocgfinpmkmlbjhcbofejhkhlbchk', // Wrong manifest.
22 manifest: getManifest('bundle/extension2.json'),
23 localizedName: 'extension.1'
24 },
25 {
26 id: 'bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb', // No CRX, 404.
27 manifest: getManifest('bundle/extension2.json'),
28 localizedName: 'extension.2'
29 }
30 ];
31
32 var installed = [
33 'begfmnajjkbjdgmffnjaojchoncnmngg'
34 ];
35
36 var failed = [
37 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',
38 'bmfoocgfinpmkmlbjhcbofejhkhlbchk',
39 'pkapffpjmiilhlhbibjhamlmdhfneidj'
40 ];
41
42 runTests([
43 function partialInstall() {
44 chrome.webstorePrivate.installBundle(
45 { localizedName: 'MyBundle' },
46 bundleItems,
47 callbackPass(function() {
48 installed.forEach(function(id) {
49 checkItemInstalled(
50 id,
51 callbackPass(function(result) { assertTrue(result); }));
52 });
53 failed.forEach(function(id) {
54 checkItemInstalled(
55 id,
56 callbackPass(function(result) { assertFalse(result); }));
57 });
58 }));
59 },
60
61 function allItemsFail() {
62 chrome.webstorePrivate.installBundle(
63 { localizedName: 'MyBundle' },
64 [bundleItems[2]],
65 callbackPass(function() {
66 checkItemInstalled(
67 bundleItems[2].id,
68 callbackPass(function(result) { assertFalse(result); }));
69 }));
70 },
71
72 function noItems() {
73 chrome.webstorePrivate.installBundle(
74 { localizedName: 'MyBundle' },
75 [],
76 callbackFail("Invalid bundle"));
77 }
78 ]);
79
80 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698