summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2016-03-14 08:59:03 +1300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-03-20 23:12:25 +0000
commit600b7007f6240c8dc26a40c3bd3e40ef16d0d3c0 (patch)
tree71a02690c35d6fc7dee69f18c88b7f4dbb53f2b8 /meta/lib/oeqa
parent8debfea81e69d038bd2d56314b272cb74f5582ed (diff)
downloadpoky-600b7007f6240c8dc26a40c3bd3e40ef16d0d3c0.tar.gz
recipetool: create: don't create extra files directory unconditionally
The extra directory next to the recipe should only be created if there are files to put into it; currently only the npm plugin does this. I didn't notice the issue earlier because the test was actually able to succeed under these circumstances if the recipe file came first in the directory listing, which was a fault in my original oe-selftest test; apparently on some YP autobuilder machines the order came out reversed. With this change we can put the oe-selftest test that highlighted the issue back to the way it was, with an extra check to reinforce that only a single file should be created. (From OE-Core rev: b8b778345eb0997c2cd952a1f61fdd2050b6b894) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa')
-rw-r--r--meta/lib/oeqa/selftest/recipetool.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/lib/oeqa/selftest/recipetool.py b/meta/lib/oeqa/selftest/recipetool.py
index 72ee110876..a04ee87db2 100644
--- a/meta/lib/oeqa/selftest/recipetool.py
+++ b/meta/lib/oeqa/selftest/recipetool.py
@@ -410,9 +410,11 @@ class RecipetoolTests(RecipetoolBase):
410 srcuri = 'http://www.dest-unreach.org/socat/download/socat-%s.tar.bz2' % pv 410 srcuri = 'http://www.dest-unreach.org/socat/download/socat-%s.tar.bz2' % pv
411 result = runCmd('recipetool create %s -o %s' % (srcuri, temprecipe)) 411 result = runCmd('recipetool create %s -o %s' % (srcuri, temprecipe))
412 dirlist = os.listdir(temprecipe) 412 dirlist = os.listdir(temprecipe)
413 if len(dirlist) < 1 or not os.path.isfile(os.path.join(temprecipe, 'socat_%s.bb' % pv)): 413 if len(dirlist) > 1:
414 self.fail('recipetool created more than just one file; output:\n%s\ndirlist:\n%s' % (result.output, str(dirlist)))
415 if len(dirlist) < 1 or not os.path.isfile(os.path.join(temprecipe, dirlist[0])):
414 self.fail('recipetool did not create recipe file; output:\n%s\ndirlist:\n%s' % (result.output, str(dirlist))) 416 self.fail('recipetool did not create recipe file; output:\n%s\ndirlist:\n%s' % (result.output, str(dirlist)))
415 self.assertIn('socat_%s.bb' % pv, dirlist, 'Recipe file incorrectly named') 417 self.assertEqual(dirlist[0], 'socat_%s.bb' % pv, 'Recipe file incorrectly named')
416 checkvars = {} 418 checkvars = {}
417 checkvars['LICENSE'] = set(['Unknown', 'GPLv2']) 419 checkvars['LICENSE'] = set(['Unknown', 'GPLv2'])
418 checkvars['LIC_FILES_CHKSUM'] = set(['file://COPYING.OpenSSL;md5=5c9bccc77f67a8328ef4ebaf468116f4', 'file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263']) 420 checkvars['LIC_FILES_CHKSUM'] = set(['file://COPYING.OpenSSL;md5=5c9bccc77f67a8328ef4ebaf468116f4', 'file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263'])