diff options
| -rw-r--r-- | bitbake/lib/bb/data_smart.py | 2 | ||||
| -rw-r--r-- | bitbake/lib/bb/tests/data.py | 6 |
2 files changed, 8 insertions, 0 deletions
diff --git a/bitbake/lib/bb/data_smart.py b/bitbake/lib/bb/data_smart.py index d6dd698eff..7dc1c68709 100644 --- a/bitbake/lib/bb/data_smart.py +++ b/bitbake/lib/bb/data_smart.py | |||
| @@ -546,6 +546,8 @@ class DataSmart(MutableMapping): | |||
| 546 | del self.dict[var]["_append"] | 546 | del self.dict[var]["_append"] |
| 547 | if "_prepend" in self.dict[var]: | 547 | if "_prepend" in self.dict[var]: |
| 548 | del self.dict[var]["_prepend"] | 548 | del self.dict[var]["_prepend"] |
| 549 | if "_remove" in self.dict[var]: | ||
| 550 | del self.dict[var]["_remove"] | ||
| 549 | if var in self.overridedata: | 551 | if var in self.overridedata: |
| 550 | active = [] | 552 | active = [] |
| 551 | self.need_overrides() | 553 | self.need_overrides() |
diff --git a/bitbake/lib/bb/tests/data.py b/bitbake/lib/bb/tests/data.py index fe947f5ba7..a4a9dd30fb 100644 --- a/bitbake/lib/bb/tests/data.py +++ b/bitbake/lib/bb/tests/data.py | |||
| @@ -283,6 +283,12 @@ class TestConcatOverride(unittest.TestCase): | |||
| 283 | self.d.setVar("TEST_remove", "val") | 283 | self.d.setVar("TEST_remove", "val") |
| 284 | self.assertEqual(self.d.getVar("TEST"), "bar") | 284 | self.assertEqual(self.d.getVar("TEST"), "bar") |
| 285 | 285 | ||
| 286 | def test_remove_cleared(self): | ||
| 287 | self.d.setVar("TEST", "${VAL} ${BAR}") | ||
| 288 | self.d.setVar("TEST_remove", "val") | ||
| 289 | self.d.setVar("TEST", "${VAL} ${BAR}") | ||
| 290 | self.assertEqual(self.d.getVar("TEST"), "val bar") | ||
| 291 | |||
| 286 | # Ensure the value is unchanged if we have an inactive remove override | 292 | # Ensure the value is unchanged if we have an inactive remove override |
| 287 | # (including that whitespace is preserved) | 293 | # (including that whitespace is preserved) |
| 288 | def test_remove_inactive_override(self): | 294 | def test_remove_inactive_override(self): |
