| OLD | NEW |
| 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 --> |
| 1 <script src="common.js"></script> | 6 <script src="common.js"></script> |
| 2 <script> | 7 <script> |
| 3 | 8 |
| 4 var extension1 = { | 9 var extension1 = { |
| 5 'id': 'bmfoocgfinpmkmlbjhcbofejhkhlbchk', | 10 'id': 'bmfoocgfinpmkmlbjhcbofejhkhlbchk', |
| 6 'manifest': | 11 'manifest': getManifest('bundle/extension1.json') |
| 7 '{\ | |
| 8 "name": "Extension Bundle 1",\ | |
| 9 "version": "1",\ | |
| 10 "manifest_version": 2,\ | |
| 11 "permissions": [ "tabs" ]\ | |
| 12 }' | |
| 13 }; | 12 }; |
| 14 | 13 |
| 15 var extension2 = { | 14 var extension2 = { |
| 16 'id': 'mpneghmdnmaolkljkipbhaienajcflfe', | 15 'id': 'mpneghmdnmaolkljkipbhaienajcflfe', |
| 17 'manifest': | 16 'manifest': getManifest('bundle/extension2.json') |
| 18 '{\ | |
| 19 "name": "Extension Bundle 2",\ | |
| 20 "version": "1",\ | |
| 21 "manifest_version": 2,\ | |
| 22 "permissions": ["management", "http://google.com" ],\ | |
| 23 "content_script": [{\ | |
| 24 "matches": [ "http://www.example.com/*" ],\ | |
| 25 "js": [ "content_script.js" ],\ | |
| 26 "run_at": "document_start"\ | |
| 27 }]\ | |
| 28 }' | |
| 29 }; | 17 }; |
| 30 | 18 |
| 31 var extension3 = { | 19 var extension3 = { |
| 32 'id': 'begfmnajjkbjdgmffnjaojchoncnmngg', | 20 'id': 'begfmnajjkbjdgmffnjaojchoncnmngg', |
| 33 'manifest': | 21 'manifest': getManifest('bundle/app2.json') |
| 34 '{\ | |
| 35 "name": "Bundle App 2",\ | |
| 36 "version": "1",\ | |
| 37 "manifest_version": 2,\ | |
| 38 "app": {\ | |
| 39 "urls": [ "http://www.testapp2.com" ],\ | |
| 40 "launch": { "web_url": "http://www.testapp2.com" }\ | |
| 41 }\ | |
| 42 }' | |
| 43 }; | 22 }; |
| 44 | 23 |
| 45 runTests([ | 24 runTests([ |
| 46 function invalidID() { | 25 function invalidID() { |
| 47 var expectedError = "Invalid id"; | 26 var expectedError = "Invalid id"; |
| 48 chrome.webstorePrivate.silentlyInstall( | 27 chrome.webstorePrivate.silentlyInstall( |
| 49 { 'id': 'dladmdjkfniedhfhcfoefgojhgaiaccc', 'manifest': getManifest() }, | 28 { 'id': 'dladmdjkfniedhfhcfoefgojhgaiaccc', 'manifest': getManifest() }, |
| 50 callbackFail(expectedError)); | 29 callbackFail(expectedError)); |
| 51 }, | 30 }, |
| 52 | 31 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 65 extension3, callbackPass(function() { | 44 extension3, callbackPass(function() { |
| 66 checkItemInstalled( | 45 checkItemInstalled( |
| 67 extension3.id, | 46 extension3.id, |
| 68 callbackPass(function(result) { assertTrue(result); })); | 47 callbackPass(function(result) { assertTrue(result); })); |
| 69 })); | 48 })); |
| 70 })); | 49 })); |
| 71 } | 50 } |
| 72 ]); | 51 ]); |
| 73 | 52 |
| 74 </script> | 53 </script> |
| OLD | NEW |