OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import os.path | 6 import os.path |
7 import re | 7 import re |
8 import shutil | 8 import shutil |
9 import sys | 9 import sys |
10 import tempfile | 10 import tempfile |
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 | 266 |
267 def MakeCmd(self, url, port): | 267 def MakeCmd(self, url, port): |
268 cmd = [self.binary, | 268 cmd = [self.binary, |
269 '--disable-web-resources', | 269 '--disable-web-resources', |
270 '--disable-preconnect', | 270 '--disable-preconnect', |
271 '--no-first-run', | 271 '--no-first-run', |
272 '--no-default-browser-check', | 272 '--no-default-browser-check', |
273 '--enable-logging', | 273 '--enable-logging', |
274 '--log-level=1', | 274 '--log-level=1', |
275 '--safebrowsing-disable-auto-update', | 275 '--safebrowsing-disable-auto-update', |
| 276 # Suppress metrics reporting. This prevents misconfigured bots, |
| 277 # people testing at their desktop, etc from poisoning the UMA data. |
| 278 '--metrics-recording-only', |
276 # Chrome explicitly blacklists some ports as "unsafe" because | 279 # Chrome explicitly blacklists some ports as "unsafe" because |
277 # certain protocols use them. Chrome gives an error like this: | 280 # certain protocols use them. Chrome gives an error like this: |
278 # Error 312 (net::ERR_UNSAFE_PORT): Unknown error | 281 # Error 312 (net::ERR_UNSAFE_PORT): Unknown error |
279 # Unfortunately, the browser tester can randomly choose a | 282 # Unfortunately, the browser tester can randomly choose a |
280 # blacklisted port. To work around this, the tester whitelists | 283 # blacklisted port. To work around this, the tester whitelists |
281 # whatever port it is using. | 284 # whatever port it is using. |
282 '--explicitly-allowed-ports=%d' % port, | 285 '--explicitly-allowed-ports=%d' % port, |
283 '--user-data-dir=%s' % self.profile] | 286 '--user-data-dir=%s' % self.profile] |
284 # Log network requests to assist debugging. | 287 # Log network requests to assist debugging. |
285 cmd.append('--log-net-log=%s' % self.NetLogName()) | 288 cmd.append('--log-net-log=%s' % self.NetLogName()) |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
320 '--trace-children=yes', | 323 '--trace-children=yes', |
321 '--nacl-file=%s' % (self.options.files[0],), | 324 '--nacl-file=%s' % (self.options.files[0],), |
322 '--ignore=../tools/valgrind/tsan/ignores.txt', | 325 '--ignore=../tools/valgrind/tsan/ignores.txt', |
323 '--suppressions=../tools/valgrind/tsan/suppressions.txt', | 326 '--suppressions=../tools/valgrind/tsan/suppressions.txt', |
324 '--log-file=%s/log.%%p' % (self.tool_log_dir,)] + cmd | 327 '--log-file=%s/log.%%p' % (self.tool_log_dir,)] + cmd |
325 elif self.options.tool != None: | 328 elif self.options.tool != None: |
326 raise LaunchFailure('Invalid tool name "%s"' % (self.options.tool,)) | 329 raise LaunchFailure('Invalid tool name "%s"' % (self.options.tool,)) |
327 cmd.extend(self.options.browser_flags) | 330 cmd.extend(self.options.browser_flags) |
328 cmd.append(url) | 331 cmd.append(url) |
329 return cmd | 332 return cmd |
OLD | NEW |