def test_refresh_from_good_absolute_git_path_env(self):
        """Good absolute path from environment is set."""
        absolute_path = shutil.which("git")

        with _rollback_refresh():
            with mock.patch.dict(os.environ, {"GIT_PYTHON_GIT_EXECUTABLE": absolute_path}):
                refresh()
                self.assertEqual(self.git.GIT_PYTHON_GIT_EXECUTABLE, absolute_path)
Good absolute path from environment is set.
test/test_git.py