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 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 if PLATFORM == 'windows' and ' ' in path: | 71 if PLATFORM == 'windows' and ' ' in path: |
72 return '"%s"' % path | 72 return '"%s"' % path |
73 return path | 73 return path |
74 | 74 |
75 | 75 |
76 def MakeEnv(options): | 76 def MakeEnv(options): |
77 env = dict(os.environ) | 77 env = dict(os.environ) |
78 # Enable PPAPI Dev interfaces for testing. | 78 # Enable PPAPI Dev interfaces for testing. |
79 env['NACL_ENABLE_PPAPI_DEV'] = str(options.enable_ppapi_dev) | 79 env['NACL_ENABLE_PPAPI_DEV'] = str(options.enable_ppapi_dev) |
80 if options.debug: | 80 if options.debug: |
81 env['PPAPI_BROWSER_DEBUG'] = '1' | |
82 env['NACL_PLUGIN_DEBUG'] = '1' | 81 env['NACL_PLUGIN_DEBUG'] = '1' |
83 env['NACL_PPAPI_PROXY_DEBUG'] = '1' | |
84 # env['NACL_SRPC_DEBUG'] = '1' | 82 # env['NACL_SRPC_DEBUG'] = '1' |
85 return env | 83 return env |
86 | 84 |
87 | 85 |
88 class BrowserLauncher(object): | 86 class BrowserLauncher(object): |
89 | 87 |
90 WAIT_TIME = 20 | 88 WAIT_TIME = 20 |
91 WAIT_STEPS = 80 | 89 WAIT_STEPS = 80 |
92 SLEEP_TIME = float(WAIT_TIME) / WAIT_STEPS | 90 SLEEP_TIME = float(WAIT_TIME) / WAIT_STEPS |
93 | 91 |
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
341 '--ignore=../tools/valgrind/tsan/ignores.txt', | 339 '--ignore=../tools/valgrind/tsan/ignores.txt', |
342 '--suppressions=../tools/valgrind/tsan/suppressions.txt', | 340 '--suppressions=../tools/valgrind/tsan/suppressions.txt', |
343 '--log-file=%s/log.%%p' % (self.tool_log_dir,)] + cmd | 341 '--log-file=%s/log.%%p' % (self.tool_log_dir,)] + cmd |
344 elif self.options.tool != None: | 342 elif self.options.tool != None: |
345 raise LaunchFailure('Invalid tool name "%s"' % (self.options.tool,)) | 343 raise LaunchFailure('Invalid tool name "%s"' % (self.options.tool,)) |
346 if self.options.enable_sockets: | 344 if self.options.enable_sockets: |
347 cmd.append('--allow-nacl-socket-api=%s' % host) | 345 cmd.append('--allow-nacl-socket-api=%s' % host) |
348 cmd.extend(self.options.browser_flags) | 346 cmd.extend(self.options.browser_flags) |
349 cmd.append(url) | 347 cmd.append(url) |
350 return cmd | 348 return cmd |
OLD | NEW |