diff options
author | mboelen <michael@cisofy.com> | 2015-10-01 17:02:09 +0300 |
---|---|---|
committer | mboelen <michael@cisofy.com> | 2015-10-01 17:02:09 +0300 |
commit | 85f6c555b213ef4cf70ca9dc3d8045bba1a16df4 (patch) | |
tree | 1ba0907fce09d364141bf8041fda75da8eac5b5e /include/tests_webservers | |
parent | 2b5c63bff9d624da117271f67e0e4bfac9637eb5 (diff) |
Minor cleanup and redirecting possible errors
Diffstat (limited to 'include/tests_webservers')
-rw-r--r-- | include/tests_webservers | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/include/tests_webservers b/include/tests_webservers index cd67c55a..5492a90f 100644 --- a/include/tests_webservers +++ b/include/tests_webservers @@ -50,18 +50,16 @@ # Test : HTTP-6622 # Description : Test for Apache installation # Notes : Do not run on NetBSD, -v is unknown option for httpd binary - # On OpenBSD do not run /usr/sbin/httpd with -v: builtin non-Apache + # On OpenBSD do not run /usr/sbin/httpd with -v: builtin non-Apache if [ ! "${OS}" = "NetBSD" ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi Register --test-no HTTP-6622 --preqs-met ${PREQS_MET} --weight L --network NO --description "Checking Apache presence" if [ ${SKIPTEST} -eq 0 ]; then - if [ "${OS}" = "OpenBSD" -a "${HTTPDBINARY}" = "/usr/sbin/httpd" ]; then - HTTPDBINARY="" - fi + if [ "${OS}" = "OpenBSD" -a "${HTTPDBINARY}" = "/usr/sbin/httpd" ]; then HTTPDBINARY=""; fi if [ "${HTTPDBINARY}" = "" ]; then Display --indent 2 --text "- Checking Apache" --result "NOT FOUND" --color WHITE else logtext "Test: Scanning for Apache binary" - IS_APACHE=`${HTTPDBINARY} -v | egrep '[aA]pache'` + IS_APACHE=`${HTTPDBINARY} -v 2> /dev/null | egrep '[aA]pache'` if [ "${IS_APACHE}" = "" ]; then logtext "Result: ${HTTPDBINARY} is not Apache" Display --indent 2 --text "- Checking Apache (binary ${HTTPDBINARY})" --result "NO MATCH" --color WHITE |