mirror of
https://github.com/deadc0de6/dotdrop.git
synced 2026-02-11 09:39:17 +00:00
tests logging
This commit is contained in:
6
tests-ng/chmod-install.sh
vendored
6
tests-ng/chmod-install.sh
vendored
@@ -33,10 +33,10 @@ echo -e "$(tput setaf 6)==> RUNNING $(basename "${BASH_SOURCE[0]}") <==$(tput sg
|
|||||||
has_rights()
|
has_rights()
|
||||||
{
|
{
|
||||||
echo "testing ${1} is ${2}"
|
echo "testing ${1} is ${2}"
|
||||||
[ ! -e "$1" ] && echo "$(basename "$1") does not exist" && exit 1
|
[ ! -e "${1}" ] && echo "${1} does not exist" && exit 1
|
||||||
local mode
|
local mode
|
||||||
mode=$(stat -L -c '%a' "$1")
|
mode=$(stat -L -c '%a' "${1}")
|
||||||
[ "${mode}" != "$2" ] && echo "bad mode for $(basename "$1") (${mode} VS expected ${2})" && exit 1
|
[ "${mode}" != "${2}" ] && echo "bad mode for $(basename "${1}") (${mode} VS expected ${2})" && exit 1
|
||||||
true
|
true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user