Set the git variables to ensure that any local gitconfig is not used or affected by the tests.
Signed-off-by: Simon Glass <s...@chromium.org> --- tools/patman/test_common.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/patman/test_common.py b/tools/patman/test_common.py index bc27b2d3cef..7da995dda22 100644 --- a/tools/patman/test_common.py +++ b/tools/patman/test_common.py @@ -109,6 +109,9 @@ class TestCommon: Returns: pygit2.Repository: repository """ + os.environ['GIT_CONFIG_GLOBAL'] = '/dev/null' + os.environ['GIT_CONFIG_SYSTEM'] = '/dev/null' + repo = pygit2.init_repository(self.gitdir) self.repo = repo new_tree = repo.TreeBuilder().write() -- 2.43.0