OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 | 2 |
3 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 3 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
4 # for details. All rights reserved. Use of this source code is governed by a | 4 # for details. All rights reserved. Use of this source code is governed by a |
5 # BSD-style license that can be found in the LICENSE file. | 5 # BSD-style license that can be found in the LICENSE file. |
6 | 6 |
7 """ | 7 """ |
8 Dart2js buildbot steps | 8 Dart2js buildbot steps |
9 | 9 |
10 Runs tests for the dart2js compiler. | 10 Runs tests for the dart2js compiler. |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 step_name = '%s-%s tests %s' % (name, runtime, ' '.join(flags)) | 150 step_name = '%s-%s tests %s' % (name, runtime, ' '.join(flags)) |
151 return step_name.strip() | 151 return step_name.strip() |
152 | 152 |
153 | 153 |
154 IsFirstTestStepCall = True | 154 IsFirstTestStepCall = True |
155 def TestStep(name, mode, system, compiler, runtime, targets, flags, arch): | 155 def TestStep(name, mode, system, compiler, runtime, targets, flags, arch): |
156 step_name = TestStepName(name, runtime, flags) | 156 step_name = TestStepName(name, runtime, flags) |
157 with bot.BuildStep(step_name, swallow_error=True): | 157 with bot.BuildStep(step_name, swallow_error=True): |
158 sys.stdout.flush() | 158 sys.stdout.flush() |
159 if NeedsXterm(compiler, runtime) and system == 'linux': | 159 if NeedsXterm(compiler, runtime) and system == 'linux': |
160 cmd = ['xvfb-run', '-a', '--server-args="-screen 0 1024x768x24"'] | 160 cmd = ['xvfb-run', '-a', '--server-args=-screen 0 1024x768x24'] |
161 else: | 161 else: |
162 cmd = [] | 162 cmd = [] |
163 | 163 |
164 user_test = os.environ.get('USER_TEST', 'no') | 164 user_test = os.environ.get('USER_TEST', 'no') |
165 | 165 |
166 cmd.extend([sys.executable, | 166 cmd.extend([sys.executable, |
167 os.path.join(os.curdir, 'tools', 'test.py'), | 167 os.path.join(os.curdir, 'tools', 'test.py'), |
168 '--step_name=' + step_name, | 168 '--step_name=' + step_name, |
169 '--mode=' + mode, | 169 '--mode=' + mode, |
170 '--compiler=' + compiler, | 170 '--compiler=' + compiler, |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
380 if build_info.mode == 'debug': | 380 if build_info.mode == 'debug': |
381 target = 'dart2js_bot_debug' | 381 target = 'dart2js_bot_debug' |
382 args = [sys.executable, './tools/build.py', '--mode=' + build_info.mode, | 382 args = [sys.executable, './tools/build.py', '--mode=' + build_info.mode, |
383 '--arch=' + build_info.arch, target] | 383 '--arch=' + build_info.arch, target] |
384 print 'Build SDK and d8: %s' % (' '.join(args)) | 384 print 'Build SDK and d8: %s' % (' '.join(args)) |
385 bot.RunProcess(args) | 385 bot.RunProcess(args) |
386 | 386 |
387 | 387 |
388 if __name__ == '__main__': | 388 if __name__ == '__main__': |
389 bot.RunBot(GetBuildInfo, RunCompilerTests, build_step=BuildCompiler) | 389 bot.RunBot(GetBuildInfo, RunCompilerTests, build_step=BuildCompiler) |
OLD | NEW |