[oe-commits] [bitbake] 03/05: tests/parse.py: Add testcase for addtask and deltask
git at git.openembedded.org
git at git.openembedded.org
Tue Apr 30 11:07:30 UTC 2019
This is an automated email from the git hooks/post-receive script.
rpurdie pushed a commit to branch master
in repository bitbake.
commit 4ac388646624e08bef848b560fa52deacf2ff4fb
Author: Robert Yang <liezhi.yang at windriver.com>
AuthorDate: Mon Apr 29 16:12:00 2019 +0800
tests/parse.py: Add testcase for addtask and deltask
Signed-off-by: Robert Yang <liezhi.yang at windriver.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
lib/bb/tests/parse.py | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/lib/bb/tests/parse.py b/lib/bb/tests/parse.py
index 1bc4740..4467d17 100644
--- a/lib/bb/tests/parse.py
+++ b/lib/bb/tests/parse.py
@@ -187,3 +187,21 @@ python () {
self.assertEqual(d1.getVar("VAR_var"), "B")
self.assertEqual(d2.getVar("VAR_var"), None)
+ addtask_deltask = """
+addtask do_patch after do_foo after do_unpack before do_configure before do_compile
+addtask do_fetch do_patch
+
+deltask do_fetch do_patch
+"""
+ def test_parse_addtask_deltask(self):
+ import sys
+ f = self.parsehelper(self.addtask_deltask)
+ d = bb.parse.handle(f.name, self.d)['']
+
+ stdout = sys.stdout.getvalue()
+ self.assertTrue("addtask contained multiple 'before' keywords" in stdout)
+ self.assertTrue("addtask contained multiple 'after' keywords" in stdout)
+ self.assertTrue('addtask ignored: " do_patch"' in stdout)
+ self.assertTrue('deltask ignored: " do_patch"' in stdout)
+ self.assertTrue('dependent task do_foo does not exist' in stdout)
+
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Openembedded-commits
mailing list