bitbake: lib/bb/tests/setup.py: unset BBPATH to ensure isolation from the existing bitbake environment

bitbake-setup deduces top directory from BBPATH, which, if set, interferes with
the tests' own setup.

(Bitbake rev: e974d42eb5229f755e14b46a00ad06b23b53e143)

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Alexander Kanavin 2025-10-02 12:09:26 +02:00 committed by Richard Purdie
parent bebbf40426
commit 9f820ce0f4

View File

@ -181,6 +181,11 @@ print("BBPATH is {{}}".format(os.environ["BBPATH"]))
def test_setup(self):
# unset BBPATH to ensure tests run in isolation from the existing bitbake environment
import os
if 'BBPATH' in os.environ:
del os.environ['BBPATH']
# check that no arguments works
self.runbbsetup("")