summaryrefslogtreecommitdiffstats
path: root/scripts/oe-selftest
diff options
context:
space:
mode:
authorMarkus Lehtonen <markus.lehtonen@linux.intel.com>2017-01-13 15:12:39 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-01-19 22:47:22 +0000
commit4e67232f345a8756f20c6dc41a52e5c80533598c (patch)
treef71cd2b35047c2cc09ee4657d9f83f95a531c66a /scripts/oe-selftest
parentdf8c0540e4b3d01fa1dcb4a569b1b1282686d60a (diff)
downloadpoky-4e67232f345a8756f20c6dc41a52e5c80533598c.tar.gz
oeqa.utils.metadata: drop 'unknown' git data elements
It's better just to not have the xml elements than to have elements with faux data. One could have git branch named 'unknown', for example. [YOCTO #10590] (From OE-Core rev: fce531c21f5e56d0f416b3405a0b0fc5ba567679) Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/oe-selftest')
-rwxr-xr-xscripts/oe-selftest4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/oe-selftest b/scripts/oe-selftest
index c3c491f20a..78806a6a22 100755
--- a/scripts/oe-selftest
+++ b/scripts/oe-selftest
@@ -603,7 +603,7 @@ def main():
603 r_branches = set(r_branches.replace('origin/', '').split()) 603 r_branches = set(r_branches.replace('origin/', '').split())
604 l_branches = {str(branch) for branch in repo.branches} 604 l_branches = {str(branch) for branch in repo.branches}
605 branch = '%s/%s/%s' % (metadata['hostname'], 605 branch = '%s/%s/%s' % (metadata['hostname'],
606 metadata['layers']['meta']['branch'], 606 metadata['layers']['meta'].get('branch', '(nogit)'),
607 metadata['machine']) 607 metadata['machine'])
608 608
609 if branch in l_branches: 609 if branch in l_branches:
@@ -631,7 +631,7 @@ def main():
631 layer_info = '' 631 layer_info = ''
632 for layer, values in metadata['layers'].items(): 632 for layer, values in metadata['layers'].items():
633 layer_info = '%s%-17s = %s:%s\n' % (layer_info, layer, 633 layer_info = '%s%-17s = %s:%s\n' % (layer_info, layer,
634 values['branch'], values['revision']) 634 values.get('branch', '(nogit)'), values.get('revision', '0'*40))
635 msg = 'Selftest for build %s of %s for machine %s on %s\n\n%s' % ( 635 msg = 'Selftest for build %s of %s for machine %s on %s\n\n%s' % (
636 log_prefix[12:], metadata['distro']['pretty_name'], 636 log_prefix[12:], metadata['distro']['pretty_name'],
637 metadata['machine'], metadata['hostname'], layer_info) 637 metadata['machine'], metadata['hostname'], layer_info)