OLD | NEW |
---|---|
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 import optparse | 4 import optparse |
5 import sys | 5 import sys |
6 import shlex | 6 import shlex |
7 import logging | 7 import logging |
8 import copy | 8 import copy |
9 | 9 |
10 from telemetry import browser_finder | 10 from telemetry import browser_finder |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
68 group.add_option( | 68 group.add_option( |
69 '--remote', | 69 '--remote', |
70 dest='cros_remote', | 70 dest='cros_remote', |
71 help='The IP address of a remote ChromeOS device to use.') | 71 help='The IP address of a remote ChromeOS device to use.') |
72 group.add_option('--identity', | 72 group.add_option('--identity', |
73 dest='cros_ssh_identity', | 73 dest='cros_ssh_identity', |
74 default=None, | 74 default=None, |
75 help='The identity file to use when ssh\'ing into the ChromeOS device') | 75 help='The identity file to use when ssh\'ing into the ChromeOS device') |
76 parser.add_option_group(group) | 76 parser.add_option_group(group) |
77 | 77 |
78 # Benchmark options | |
79 group = optparse.OptionGroup(parser, 'Benchmark options') | |
80 group.add_option('--performance-test', action='store_true', | |
tonyg
2013/02/21 18:07:08
Why is this an option? Shouldn't we just do this b
bulach
2013/02/22 11:54:25
good point, removed..
| |
81 dest='performance_test', | |
82 help='Run the benchmark in full power mode (if the underlying platform ' | |
83 'supports).') | |
84 | |
78 # Browser options | 85 # Browser options |
79 group = optparse.OptionGroup(parser, 'Browser options') | 86 group = optparse.OptionGroup(parser, 'Browser options') |
80 group.add_option('--dont-override-profile', action='store_true', | 87 group.add_option('--dont-override-profile', action='store_true', |
81 dest='dont_override_profile', | 88 dest='dont_override_profile', |
82 help='Uses the regular user profile instead of a clean one') | 89 help='Uses the regular user profile instead of a clean one') |
83 group.add_option('--extra-browser-args', | 90 group.add_option('--extra-browser-args', |
84 dest='extra_browser_args_as_string', | 91 dest='extra_browser_args_as_string', |
85 help='Additional arguments to pass to the browser when it starts') | 92 help='Additional arguments to pass to the browser when it starts') |
86 group.add_option('--show-stdout', | 93 group.add_option('--show-stdout', |
87 action='store_true', | 94 action='store_true', |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
147 self.extra_browser_args_as_string) # pylint: disable=E1101 | 154 self.extra_browser_args_as_string) # pylint: disable=E1101 |
148 self.extra_browser_args.extend(tmp) | 155 self.extra_browser_args.extend(tmp) |
149 delattr(self, 'extra_browser_args_as_string') | 156 delattr(self, 'extra_browser_args_as_string') |
150 return ret | 157 return ret |
151 parser.parse_args = ParseArgs | 158 parser.parse_args = ParseArgs |
152 return parser | 159 return parser |
153 | 160 |
154 def AppendExtraBrowserArg(self, arg): | 161 def AppendExtraBrowserArg(self, arg): |
155 if arg not in self.extra_browser_args: | 162 if arg not in self.extra_browser_args: |
156 self.extra_browser_args.append(arg) | 163 self.extra_browser_args.append(arg) |
OLD | NEW |