You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
QA/tests/p_initscripts/initscripts_service_status.sh

21 lines
470 B

#!/bin/bash
# Author: Athmane Madjoudj <athmanem@gmail.com>
if [ "$CONTAINERTEST" -eq "1" ]; then
t_Log "Running in container -> SKIP"
exit 0
fi
t_Log "Running $0 - check if service cmd can get service status"
output_file=$(mktemp)
trap "rm -f ${output_file}" EXIT
# auditd is used as example because it's standard with minimal install
if ! service auditd status > ${output_file} 2>&1; then
cat ${output_file}
t_CheckExitStatus 1
fi
t_CheckExitStatus 0