From: Rob Browning Date: Sun, 8 Mar 2015 20:37:20 +0000 (-0500) Subject: sampledata: use a local absolute symlink, not /etc X-Git-Tag: 0.27-rc2~12 X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?p=bup.git;a=commitdiff_plain;h=762dff06850ff15cc400a653d0e9778af9998139 sampledata: use a local absolute symlink, not /etc Signed-off-by: Rob Browning Tested-by: Rob Browning --- diff --git a/lib/bup/t/tindex.py b/lib/bup/t/tindex.py index 5477506..a29fa3a 100644 --- a/lib/bup/t/tindex.py +++ b/lib/bup/t/tindex.py @@ -14,10 +14,12 @@ def index_basic(): cd = os.path.realpath('../../../t') WVPASS(cd) sd = os.path.realpath(cd + '/sampledata') - WVPASSEQ(index.realpath(cd + '/sampledata'), cd + '/sampledata') + WVPASSEQ(index.realpath(cd + '/sampledata'), sd) WVPASSEQ(os.path.realpath(cd + '/sampledata/x'), sd + '/x') - WVPASSEQ(os.path.realpath(cd + '/sampledata/etc'), os.path.realpath('/etc')) - WVPASSEQ(index.realpath(cd + '/sampledata/etc'), sd + '/etc') + WVPASSEQ(os.path.realpath(cd + '/sampledata/abs-symlink'), + sd + '/abs-symlink-target') + WVPASSEQ(index.realpath(cd + '/sampledata/abs-symlink'), + sd + '/abs-symlink') @wvtest diff --git a/t/configure-sampledata b/t/configure-sampledata index 79bf8a4..1b61ddc 100755 --- a/t/configure-sampledata +++ b/t/configure-sampledata @@ -1,5 +1,7 @@ #!/usr/bin/env bash +set -o pipefail + top=$(pwd) usage() @@ -17,7 +19,7 @@ case "$1" in cd t/sampledata || exit $? ln -sf a b || exit $? ln -sf b c || exit $? - ln -sf /etc . || exit $? + ln -sf "$(pwd)/abs-symlink-target" abs-symlink || exit $? ) || exit $? ;; '--clean')