caf164f test: add user_xattr check for securityselinuxlabeltest

1 file Authored by Jincheng Miao 9 years ago, Committed by ericb 9 years ago,
    test: add user_xattr check for securityselinuxlabeltest
    
    libvirt unit test used setxattr with "user.libvirt.selinux" name to
    emulate setfilecon of selinux. But for some old kernel filesystem
    (like 2.6.32-431.el6.x86_64), if the filesystem is not mounted with
    user_xattr flag, the setxattr with "user.libvirt.selinux" will fail.
    
    So adding testUserXattrEnabled() in securityselinuxlabeltest.c,
    if user_xattr is not enabled, skip this case.
    
    The user_xattr is departed in newer kernel, therefore this commit is
    only for the compatablity for old kernel.
    
    Signed-off-by: Jincheng Miao <jmiao@redhat.com>
    Signed-off-by: Eric Blake <eblake@redhat.com>
    Tested-by: Scott Sullivan <ssullivan@liquidweb.com>