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

Side by Side Diff: chrome/test/mini_installer/test_installer.py

Issue 2802713002: Enable side-by-side beta and dev channels. (Closed)
Patch Set: add missing test stanza for reland Created 3 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
1 # Copyright 2013 The Chromium Authors. All rights reserved. 1 # Copyright 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """This script tests the installer with test cases specified in the config file. 5 """This script tests the installer with test cases specified in the config file.
6 6
7 For each test case, it checks that the machine states after the execution of 7 For each test case, it checks that the machine states after the execution of
8 each command match the expected machine states. For more details, take a look at 8 each command match the expected machine states. For more details, take a look at
9 the design documentation at http://goo.gl/Q0rGM6 9 the design documentation at http://goo.gl/Q0rGM6
10 """ 10 """
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 variable_expander: A VariableExpander object. 200 variable_expander: A VariableExpander object.
201 """ 201 """
202 # A list of (system_level, product_name, product_switch, registry_subkey) 202 # A list of (system_level, product_name, product_switch, registry_subkey)
203 # tuples for the possible installed products. 203 # tuples for the possible installed products.
204 data = [ 204 data = [
205 (False, '$CHROME_LONG_NAME', '', 205 (False, '$CHROME_LONG_NAME', '',
206 '$CHROME_UPDATE_REGISTRY_SUBKEY'), 206 '$CHROME_UPDATE_REGISTRY_SUBKEY'),
207 (True, '$CHROME_LONG_NAME', '--system-level', 207 (True, '$CHROME_LONG_NAME', '--system-level',
208 '$CHROME_UPDATE_REGISTRY_SUBKEY'), 208 '$CHROME_UPDATE_REGISTRY_SUBKEY'),
209 ] 209 ]
210 if variable_expander.Expand('$SUPPORTS_SXS') == 'True': 210 if variable_expander.Expand('$BRAND') == 'Google Chrome':
211 data.append((False, '$CHROME_LONG_NAME_SXS', '', 211 data.extend([(False, '$CHROME_LONG_NAME_BETA', '',
212 '$CHROME_UPDATE_REGISTRY_SUBKEY_SXS')) 212 '$CHROME_UPDATE_REGISTRY_SUBKEY_BETA'),
213 (True, '$CHROME_LONG_NAME_BETA', '--system-level',
214 '$CHROME_UPDATE_REGISTRY_SUBKEY_BETA'),
215 (False, '$CHROME_LONG_NAME_DEV', '',
216 '$CHROME_UPDATE_REGISTRY_SUBKEY_DEV'),
217 (True, '$CHROME_LONG_NAME_DEV', '--system-level',
218 '$CHROME_UPDATE_REGISTRY_SUBKEY_DEV'),
219 (False, '$CHROME_LONG_NAME_SXS', '',
220 '$CHROME_UPDATE_REGISTRY_SUBKEY_SXS')])
213 221
214 interactive_option = '--interactive' if not force_clean else '' 222 interactive_option = '--interactive' if not force_clean else ''
215 for system_level, product_name, product_switch, registry_subkey in data: 223 for system_level, product_name, product_switch, registry_subkey in data:
216 command = ('python uninstall_chrome.py ' 224 command = ('python uninstall_chrome.py '
217 '--chrome-long-name="%s" ' 225 '--chrome-long-name="%s" '
218 '--no-error-if-absent %s %s' % 226 '--no-error-if-absent %s %s' %
219 (product_name, product_switch, interactive_option)) 227 (product_name, product_switch, interactive_option))
220 try: 228 try:
221 RunCommand(command, variable_expander) 229 RunCommand(command, variable_expander)
222 except: 230 except:
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
442 trie[path] = value 450 trie[path] = value
443 return 451 return
444 directory, rest = path.split(TEST_SEPARATOR, 1) 452 directory, rest = path.split(TEST_SEPARATOR, 1)
445 if directory not in trie: 453 if directory not in trie:
446 trie[directory] = {} 454 trie[directory] = {}
447 _AddPathToTrie(trie[directory], rest, value) 455 _AddPathToTrie(trie[directory], rest, value)
448 456
449 457
450 if __name__ == '__main__': 458 if __name__ == '__main__':
451 sys.exit(main()) 459 sys.exit(main())
OLDNEW
« no previous file with comments | « chrome/test/mini_installer/mini_installer_test.gni ('k') | chrome/test/mini_installer/variable_expander.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698