Fix mb.py try command and docs
I seemed to have messed up and not uploaded the last changes I made to https://crrev.com/c/1856822. I had meant to switch to ninja targets, but the CL doesn't have those changes. Bug: 1015682 Change-Id: Iefff69a47a682f2bc5ca549dc65348bd65536981 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1869836 Commit-Queue: Stephen Martinis <martiniss@chromium.org> Reviewed-by: Dirk Pranke <dpranke@chromium.org> Auto-Submit: Stephen Martinis <martiniss@chromium.org> Cr-Commit-Position: refs/heads/master@{#707601}
This commit is contained in:

committed by
Commit Bot

parent
ed87a7ea41
commit
9388ffc87f
tools/mb
@ -171,7 +171,7 @@ to be run inside the isolate.
|
||||
Tries your change on the trybots. Right now this is essentially a fancy tryjob,
|
||||
like one you could trigger via `git cl try` or via CQ dry runs. Basic usage is
|
||||
|
||||
`mb.py try -m tryserver.chromium.linux -b linux-rel //base:base_unittests`
|
||||
`mb.py try -m tryserver.chromium.linux -b linux-rel base_unittests`
|
||||
|
||||
Your change must be uploaded to Gerrit. Local changes will not be uploaded for
|
||||
you. It uses the gerrit CL associated with your given git branch.
|
||||
@ -182,7 +182,7 @@ for a mapping of which bots are on which tryservers, and what those bots mirror.
|
||||
Any trybot in `trybots.py` is supported; you can test your code on windows, for
|
||||
example. The tryjob will compile and run your code on windows.
|
||||
|
||||
The target (`base_unittests`) in the example is a GN build target. Most GN
|
||||
The target (`base_unittests`) in the example is a ninja build target. Most ninja
|
||||
unittest targets can be put here which currently runs on the bots.
|
||||
|
||||
### mb validate
|
||||
|
@ -384,20 +384,11 @@ class MetaBuildWrapper(object):
|
||||
return 0
|
||||
|
||||
def CmdTry(self):
|
||||
target = self.args.target
|
||||
if not target.startswith('//'):
|
||||
self.Print("Expected a GN target like //:foo, got %s" % target)
|
||||
ninja_target = self.args.target
|
||||
if ninja_target.startswith('//'):
|
||||
self.Print("Expected a nijna target like base_unittests, got %s" % target)
|
||||
return 1
|
||||
|
||||
recipe_name = None
|
||||
isolate_map = self.ReadIsolateMap()
|
||||
for name, config in isolate_map.iteritems():
|
||||
if 'label' in config and config['label'] == target:
|
||||
recipe_name = name
|
||||
break
|
||||
if not recipe_name:
|
||||
self.Print("Unable to find a recipe entry for %s." % target)
|
||||
|
||||
json_path = self.PathJoin(self.chromium_src_dir, 'out.json')
|
||||
try:
|
||||
ret, out, err = self.Run(
|
||||
@ -430,7 +421,7 @@ class MetaBuildWrapper(object):
|
||||
# TODO(martiniss): maybe don't always assume the bucket?
|
||||
'led', 'get-builder', 'luci.chromium.try:%s' % self.args.builder).then(
|
||||
'led', 'edit', '-r', 'chromium_trybot_experimental',
|
||||
'-p', 'tests=["%s"]' % recipe_name).then(
|
||||
'-p', 'tests=["%s"]' % ninja_target).then(
|
||||
'led', 'edit-cr-cl', issue_data['issue_url']).then(
|
||||
'led', 'launch').result
|
||||
|
||||
|
Reference in New Issue
Block a user