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

Side by Side Diff: tools/bots/compiler.py

Issue 220703003: Always print the runtime as part of the stepname (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 return bot.BuildInfo(compiler, runtime, mode, system, checked, host_checked, 133 return bot.BuildInfo(compiler, runtime, mode, system, checked, host_checked,
134 minified, shard_index, total_shards, is_buildbot, 134 minified, shard_index, total_shards, is_buildbot,
135 test_set, csp, arch, dart2js_full) 135 test_set, csp, arch, dart2js_full)
136 136
137 137
138 def NeedsXterm(compiler, runtime): 138 def NeedsXterm(compiler, runtime):
139 return runtime in ['ie9', 'ie10', 'ie11', 'chrome', 'safari', 'opera', 139 return runtime in ['ie9', 'ie10', 'ie11', 'chrome', 'safari', 'opera',
140 'ff', 'drt', 'dartium'] 140 'ff', 'drt', 'dartium']
141 141
142 142
143 def TestStepName(name, flags): 143 def TestStepName(name, runtime, flags):
144 # Filter out flags with '=' as this breaks the /stats feature of the 144 # Filter out flags with '=' as this breaks the /stats feature of the
145 # build bot. 145 # build bot.
146 flags = [x for x in flags if not '=' in x] 146 flags = [x for x in flags if not '=' in x]
147 return ('%s tests %s' % (name, ' '.join(flags))).strip() 147 step_name = '%s-%s tests %s' % (name, runtime, ' '.join(flags))
148 return step_name.strip()
148 149
149 150
150 IsFirstTestStepCall = True 151 IsFirstTestStepCall = True
151 def TestStep(name, mode, system, compiler, runtime, targets, flags, arch): 152 def TestStep(name, mode, system, compiler, runtime, targets, flags, arch):
152 step_name = TestStepName(name, flags) 153 step_name = TestStepName(name, runtime, flags)
153 with bot.BuildStep(step_name, swallow_error=True): 154 with bot.BuildStep(step_name, swallow_error=True):
154 sys.stdout.flush() 155 sys.stdout.flush()
155 if NeedsXterm(compiler, runtime) and system == 'linux': 156 if NeedsXterm(compiler, runtime) and system == 'linux':
156 cmd = ['xvfb-run', '-a'] 157 cmd = ['xvfb-run', '-a']
157 else: 158 else:
158 cmd = [] 159 cmd = []
159 160
160 user_test = os.environ.get('USER_TEST', 'no') 161 user_test = os.environ.get('USER_TEST', 'no')
161 162
162 cmd.extend([sys.executable, 163 cmd.extend([sys.executable,
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 # Run the unit tests in checked mode (the VM's checked mode). 260 # Run the unit tests in checked mode (the VM's checked mode).
260 unit_test_flags.append('--checked') 261 unit_test_flags.append('--checked')
261 TestStep("dart2js_unit", mode, system, 'none', 'vm', ['dart2js'], 262 TestStep("dart2js_unit", mode, system, 'none', 'vm', ['dart2js'],
262 unit_test_flags, arch) 263 unit_test_flags, arch)
263 264
264 if compiler == 'dart2js' and runtime in ['ie10', 'ie11']: 265 if compiler == 'dart2js' and runtime in ['ie10', 'ie11']:
265 TestStep("%s-%s" % (compiler, runtime), mode, system, compiler, runtime, 266 TestStep("%s-%s" % (compiler, runtime), mode, system, compiler, runtime,
266 ['html', 'pkg', 'samples'], flags, arch) 267 ['html', 'pkg', 'samples'], flags, arch)
267 else: 268 else:
268 # Run the default set of test suites. 269 # Run the default set of test suites.
269 TestStep("%s-%s" % (compiler, runtime), mode, system, compiler, 270 TestStep(compiler, mode, system, compiler,
270 runtime, [], flags, arch) 271 runtime, [], flags, arch)
271 272
272 if compiler == 'dart2js': 273 if compiler == 'dart2js':
273 # TODO(kasperl): Consider running peg and css tests too. 274 # TODO(kasperl): Consider running peg and css tests too.
274 extras = ['dart2js_extra', 'dart2js_native'] 275 extras = ['dart2js_extra', 'dart2js_native']
275 extras_flags = flags 276 extras_flags = flags
276 if (system == 'linux' 277 if (system == 'linux'
277 and runtime == 'd8' 278 and runtime == 'd8'
278 and not '--host-checked' in extras_flags): 279 and not '--host-checked' in extras_flags):
279 # Run the extra tests in checked mode, but only on linux/d8. 280 # Run the extra tests in checked mode, but only on linux/d8.
280 # Other systems have less resources and tend to time out. 281 # Other systems have less resources and tend to time out.
281 extras_flags = extras_flags + ['--host-checked'] 282 extras_flags = extras_flags + ['--host-checked']
282 TestStep("dart2js_extra", mode, system, 'dart2js', runtime, extras, 283 TestStep('dart2js_extra', mode, system, 'dart2js', runtime, extras,
283 extras_flags, arch) 284 extras_flags, arch)
284 285
285 TestStep("try_dart", mode, system, 'dart2js', runtime, ['try'], 286 TestStep('try_dart', mode, system, 'dart2js', runtime, ['try'],
286 extras_flags, arch) 287 extras_flags, arch)
287 288
288 289
289 def GetHasHardCodedCheckedMode(build_info): 290 def GetHasHardCodedCheckedMode(build_info):
290 # TODO(ricow): We currently run checked mode tests on chrome on linux and 291 # TODO(ricow): We currently run checked mode tests on chrome on linux and
291 # on the slow (all) IE windows bots. This is a hack and we should use the 292 # on the slow (all) IE windows bots. This is a hack and we should use the
292 # normal sharding and checked splitting functionality when we get more 293 # normal sharding and checked splitting functionality when we get more
293 # vms for testing this. 294 # vms for testing this.
294 if (build_info.system == 'linux' and build_info.runtime == 'drt'): 295 if (build_info.system == 'linux' and build_info.runtime == 'drt'):
295 return True 296 return True
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 """ 372 """
372 with bot.BuildStep('Build SDK'): 373 with bot.BuildStep('Build SDK'):
373 args = [sys.executable, './tools/build.py', '--mode=' + build_info.mode, 374 args = [sys.executable, './tools/build.py', '--mode=' + build_info.mode,
374 '--arch=' + build_info.arch, 'dart2js_bot'] 375 '--arch=' + build_info.arch, 'dart2js_bot']
375 print 'Build SDK and d8: %s' % (' '.join(args)) 376 print 'Build SDK and d8: %s' % (' '.join(args))
376 bot.RunProcess(args) 377 bot.RunProcess(args)
377 378
378 379
379 if __name__ == '__main__': 380 if __name__ == '__main__':
380 bot.RunBot(GetBuildInfo, RunCompilerTests, build_step=BuildCompiler) 381 bot.RunBot(GetBuildInfo, RunCompilerTests, build_step=BuildCompiler)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698