Added brew as package manager.

This commit is contained in:
Kamil Boratyński 2016-03-22 23:06:10 +01:00
parent 9023aaa052
commit 85236bb996
1 changed files with 26 additions and 0 deletions

View File

@ -32,6 +32,9 @@
#
Display --indent 2 --text "- Searching package managers"
#
#################################################################################
#
# Test : PKGS-7301
# Description : Query FreeBSD pkg
if [ -x /usr/sbin/pkg ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
@ -80,6 +83,29 @@
done
Report "installed_packages=${N}"
fi
#
#################################################################################
#
# Test : PKGS-7303
# Description : Query brew package manager
if [ `type -p brew` ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
Register --test-no PKGS-7303 --preqs-met ${PREQS_MET} --weight L --network NO --description "Query brew package manager"
if [ ${SKIPTEST} -eq 0 ]; then
Display --indent 4 --text "- Searching brew" --result FOUND --color GREEN
LogText "Result: Found brew"
Report "package_manager[]=brew"
LogText "Test: Querying brew to get package list"
Display --indent 4 --text "- Querying brew for installed packages"
LogText "Output:"; LogText "-----"
GPACKAGES=`brew list`
for J in ${GPACKAGES}; do
LogText "Found package ${J}"
INSTALLED_PACKAGES="${INSTALLED_PACKAGES}|${J}"
done
else
LogText "Result: brew can NOT be found on this system"
fi
#
#################################################################################
#