summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Istrate <daniel.alexandrux.istrate@intel.com>2016-02-16 17:40:32 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-02-18 07:39:30 +0000
commit9cd64edebf1b559c07fa9387a9013f7ec76648ce (patch)
tree59b9239b4b9486107c14fb4560bcd47e971f5012
parent7e5b45146242b5cccd0a1649f525555488f2e1c7 (diff)
downloadpoky-9cd64edebf1b559c07fa9387a9013f7ec76648ce.tar.gz
oeqa/selftest/bbtests: Test bitbake --setscene-only option
Bitbake option to restore from sstate only within a build (i.e. execute no real tasks, only setscene) fix for [YOCTO #8876] (From OE-Core rev: 3821aee0129b87a859b3a540b82745fdae184721) Signed-off-by: Daniel Istrate <daniel.alexandrux.istrate@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oeqa/selftest/bbtests.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/meta/lib/oeqa/selftest/bbtests.py b/meta/lib/oeqa/selftest/bbtests.py
index 42ae9d0cc9..70e5b29218 100644
--- a/meta/lib/oeqa/selftest/bbtests.py
+++ b/meta/lib/oeqa/selftest/bbtests.py
@@ -232,3 +232,18 @@ SSTATE_DIR = \"${TOPDIR}/download-selftest\"
232 self.assertEqual(result.status, 0, "Bitbake failed, exit code %s, output %s" % (result.status, result.output)) 232 self.assertEqual(result.status, 0, "Bitbake failed, exit code %s, output %s" % (result.status, result.output))
233 self.assertFalse(os.path.isfile(os.path.join(self.builddir, 'tmp/deploy/licenses/readline/generic_GPLv3'))) 233 self.assertFalse(os.path.isfile(os.path.join(self.builddir, 'tmp/deploy/licenses/readline/generic_GPLv3')))
234 self.assertTrue(os.path.isfile(os.path.join(self.builddir, 'tmp/deploy/licenses/readline/generic_GPLv2'))) 234 self.assertTrue(os.path.isfile(os.path.join(self.builddir, 'tmp/deploy/licenses/readline/generic_GPLv2')))
235
236 @testcase(1422)
237 def test_setscene_only(self):
238 """ Bitbake option to restore from sstate only within a build (i.e. execute no real tasks, only setscene)"""
239 test_recipe = 'ed'
240
241 bitbake(test_recipe)
242 bitbake('-c clean %s' % test_recipe)
243 ret = bitbake('--setscene-only %s' % test_recipe)
244
245 tasks = re.findall(r'task\s+(do_\S+):', ret.output)
246
247 for task in tasks:
248 self.assertIn('_setscene', task, 'A task different from _setscene ran: %s.\n'
249 'Executed tasks were: %s' % (task, str(tasks)))