[Concept,05/15] buildman: Deal with DTC in environemnt in test_skip_dtc()

Message ID 20250819193918.874215-6-sjg@u-boot.org
State New
Headers
Series test: Improvements to make check et al |

Commit Message

Simon Glass Aug. 19, 2025, 7:39 p.m. UTC
  From: Simon Glass <sjg@chromium.org>

If DTC happens to be set in the environment provided to buildman itself,
this test currently fails. Fix it by removing any DTC variable before
starting the test.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

 tools/buildman/test.py | 1 +
 1 file changed, 1 insertion(+)
  

Patch

diff --git a/tools/buildman/test.py b/tools/buildman/test.py
index 735203e934c..c7000b58bdf 100644
--- a/tools/buildman/test.py
+++ b/tools/buildman/test.py
@@ -1012,6 +1012,7 @@  class TestBuild(unittest.TestCase):
 
     def test_skip_dtc(self):
         """Test skipping building the dtc tool"""
+        os.environ.pop('DTC', None)
         old_path = os.getenv('PATH')
         try:
             os.environ['PATH'] = self.base_dir