'Add user (if exists) to group (if exists)'

def add_user_to_group(self, user, group):

    if (user not in self.get_user_map()):
        raise exception.BaseException(('user    %s    does    not    exist' % user))
    if (group in self.get_group_map()):
        self.ssh.execute(('gpasswd    -a    %s    %s' % (user, 'utmp')))
    else:
        raise exception.BaseException(('group    %s    does    not    exist' % group))
