diff -r 48b0adfe3059 -r 2e8a0b26d579 test/relocate.sh --- a/test/relocate.sh Thu Jan 22 22:54:45 2009 +0000 +++ b/test/relocate.sh Sat Jun 11 17:56:45 2016 +0100 @@ -1,7 +1,12 @@ #!/bin/sh +if [ $# -gt 0 ]; then + razor="$1" +else + razor=../src/razor +fi check_file() { - ../src/razor list-files | grep -x "$1" > /dev/null + $razor list-files | grep -x "$1" > /dev/null if [ $? -ne 0 ]; then echo $1: Not in database >&2 exit 1 @@ -12,11 +17,11 @@ fi } export RAZOR_ROOT=`mktemp -dt` || exit 1 -../src/razor init || exit 1 +$razor init || exit 1 export YUM_URL="file://localhost/`pwd`" -../src/razor import-yum || exit 1 -../src/razor install zap || exit 1 -../src/razor install --relocate /usr=/opt --relocate /etc=/opt/etc zsh || exit 1 +$razor import-yum || exit 1 +$razor install zap || exit 1 +$razor install --relocate /usr=/opt --relocate /etc=/opt/etc zsh || exit 1 check_file /etc/zsh.conf check_file /usr/bin/zap check_file /opt/bin/zip