diff --git a/tests/p_tftp-server/20-tftp-server_put-test.sh b/tests/p_tftp-server/20-tftp-server_put-test.sh index e12619a..bf257f8 100755 --- a/tests/p_tftp-server/20-tftp-server_put-test.sh +++ b/tests/p_tftp-server/20-tftp-server_put-test.sh @@ -16,12 +16,17 @@ echo "t_functional_test" > put_test touch $TFTP_DIR/put_test chmod 666 $TFTP_DIR/put_test -# Fix selinux bool on c6 -if (t_GetPkgRel basesystem | grep -q el6) -then - setsebool tftp_anon_write 1 +# Fix selinux bool +dist=$(t_DistCheck) +if [ "$dist" = "6" ]; then + setsebool tftp_anon_write 1 +elif [ "$dist" = "5" ]; then + setsebool allow_tftp_anon_write 1 +else + echo undefined fi + tftp 127.0.0.1 -c put put_test cat $TFTP_DIR/put_test | grep -q 't_functional_test'