Refactor test for smack_*getlabel and smack_*setlabel.