human
Complete this python program:
def __check_git_version(caller, min_version, skip_msg):
assistant
#Here is the Python program you requested.

    """Common logic for version check
    """
    if inspect.isclass(caller):
        actual_setup = getattr(caller, 'setUp', None)
        def setUp(self, *args, **kwargs):
            if (not salt.utils.path.which('git')):
                self.skipTest('git    is    not    installed')
            git_version = self.run_function('git.version')
            if (_LooseVersion(git_version) < _LooseVersion(min_version)):
                self.skipTest(skip_msg.format(min_version, git_version))
            if (actual_setup is not None):
                actual_setup(self, *args, **kwargs)
        caller.setUp = setUp
        return caller
    @functools.wraps(caller)
    def wrapper(self, *args, **kwargs):
        if (not salt.utils.path.which('git')):
            self.skipTest('git    is    not    installed')
        git_version = self.run_function('git.version')
        if (_LooseVersion(git_version) < _LooseVersion(min_version)):
            self.skipTest(skip_msg.format(min_version, git_version))
        return caller(self, *args, **kwargs)
    return wrapper