summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/selftest/recipetool.py
diff options
context:
space:
mode:
Diffstat (limited to 'meta/lib/oeqa/selftest/recipetool.py')
-rw-r--r--meta/lib/oeqa/selftest/recipetool.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/recipetool.py b/meta/lib/oeqa/selftest/recipetool.py
index bbfce7c394..34e383f772 100644
--- a/meta/lib/oeqa/selftest/recipetool.py
+++ b/meta/lib/oeqa/selftest/recipetool.py
@@ -401,6 +401,25 @@ class RecipetoolTests(RecipetoolBase):
401 inherits = ['autotools', 'pkgconfig'] 401 inherits = ['autotools', 'pkgconfig']
402 self._test_recipe_contents(recipefile, checkvars, inherits) 402 self._test_recipe_contents(recipefile, checkvars, inherits)
403 403
404 def test_recipetool_create_simple(self):
405 # Try adding a recipe
406 temprecipe = os.path.join(self.tempdir, 'recipe')
407 os.makedirs(temprecipe)
408 pv = '1.7.3.0'
409 srcuri = 'http://www.dest-unreach.org/socat/download/socat-%s.tar.bz2' % pv
410 result = runCmd('recipetool create %s -o %s' % (srcuri, temprecipe))
411 dirlist = os.listdir(temprecipe)
412 if len(dirlist) < 1 or not os.path.isfile(os.path.join(temprecipe, dirlist[0])):
413 self.fail('recipetool did not create recipe file; output:\n%s' % result.output)
414 self.assertEqual(dirlist[0], 'socat_%s.bb' % pv, 'Recipe file incorrectly named')
415 checkvars = {}
416 checkvars['LICENSE'] = 'Unknown GPLv2'
417 checkvars['LIC_FILES_CHKSUM'] = 'file://COPYING.OpenSSL;md5=5c9bccc77f67a8328ef4ebaf468116f4 file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263'
418 # We don't check DEPENDS since they are variable for this recipe depending on what's in the sysroot
419 checkvars['S'] = None
420 checkvars['SRC_URI'] = srcuri.replace(pv, '${PV}')
421 inherits = ['autotools']
422 self._test_recipe_contents(os.path.join(temprecipe, dirlist[0]), checkvars, inherits)
404 423
405class RecipetoolAppendsrcBase(RecipetoolBase): 424class RecipetoolAppendsrcBase(RecipetoolBase):
406 def _try_recipetool_appendsrcfile(self, testrecipe, newfile, destfile, options, expectedlines, expectedfiles): 425 def _try_recipetool_appendsrcfile(self, testrecipe, newfile, destfile, options, expectedlines, expectedfiles):