summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/tests
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@intel.com>2015-02-02 15:09:24 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-02-03 12:21:36 +0000
commitb00e781b4a6f756ab8f83e0cda3a5ebae2d20be1 (patch)
tree90e7fb61529f40bbd68646795329a6da5d7f0049 /bitbake/lib/bb/tests
parent22c38e2d8a058619e3d05534b5e830b750aa4241 (diff)
downloadpoky-b00e781b4a6f756ab8f83e0cda3a5ebae2d20be1.tar.gz
bitbake: tests/data: add test for incorrect remove behaviour
The _remove operator isn't working correctly when used with a variable that expands to several items, so add a test case to exercise this path. (Bitbake rev: cb2a62a5fbffb358528a85b46c1fc6383286cb9d) Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/tests')
-rw-r--r--bitbake/lib/bb/tests/data.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/bitbake/lib/bb/tests/data.py b/bitbake/lib/bb/tests/data.py
index 81e4091ff7..7994a88a78 100644
--- a/bitbake/lib/bb/tests/data.py
+++ b/bitbake/lib/bb/tests/data.py
@@ -272,6 +272,13 @@ class TestConcatOverride(unittest.TestCase):
272 bb.data.update_data(self.d) 272 bb.data.update_data(self.d)
273 self.assertEqual(self.d.getVar("TEST", True), "Y") 273 self.assertEqual(self.d.getVar("TEST", True), "Y")
274 274
275 def test_remove_expansion_items(self):
276 self.d.setVar("TEST", "A B C D")
277 self.d.setVar("BAR", "B D")
278 self.d.setVar("TEST_remove", "${BAR}")
279 bb.data.update_data(self.d)
280 self.assertEqual(self.d.getVar("TEST", True), "A C")
281
275class TestOverrides(unittest.TestCase): 282class TestOverrides(unittest.TestCase):
276 def setUp(self): 283 def setUp(self):
277 self.d = bb.data.init() 284 self.d = bb.data.init()