#!/usr/bin/bats load ../../library/assertions; PACKAGE=httpd setup() { if [[ -z $(/bin/rpm -qa | /bin/grep ${PACKAGE}) ]]; then skip "${PACKAGE} is not installed, tests skipped" fi } @test "is httpd service present" { /bin/systemctl status ${PACKAGE} | /bin/grep -E 'running;|disabled;' assert_success; }