[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[committed] Use execs var in tests to find test executables



Hi,

Currently, in order to access a test executable hello, test-cases use a
hardcoded path ../hello.

Instead, pass an execs variable to the testcases, and access hello using
$execs/hello.

Committed to trunk.

Thanks,
- Tom

Use execs var in tests to find test executables

2019-04-12  Tom de Vries  <tdevries@suse.de>

	* testsuite/dwz.tests/dwz-tests.exp: Set execs variable.
	* testsuite/dwz.tests/devel-ignore-locus.sh: Use execs variable.
	* testsuite/dwz.tests/devel-ignore-size.sh: Same.
	* testsuite/dwz.tests/devel-trace.sh: Same.
	* testsuite/dwz.tests/dwz.sh: Same.
	* testsuite/dwz.tests/eu-strip-unstrip-multifile.sh: Same.
	* testsuite/dwz.tests/eu-strip-unstrip.sh: Same.
	* testsuite/dwz.tests/gdb-add-index.sh: Same.
	* testsuite/dwz.tests/hardlink-multifile.sh: Same.
	* testsuite/dwz.tests/hardlink.sh: Same.
	* testsuite/dwz.tests/help.sh: Same.
	* testsuite/dwz.tests/illegal-option.sh: Same.
	* testsuite/dwz.tests/low-mem.sh: Same.
	* testsuite/dwz.tests/multifile-name.sh: Same.
	* testsuite/dwz.tests/multifile-relative.sh: Same.
	* testsuite/dwz.tests/multifile.sh: Same.
	* testsuite/dwz.tests/objcopy-remove-debug-abbrev.sh: Same.
	* testsuite/dwz.tests/objcopy-strip-debug.sh: Same.
	* testsuite/dwz.tests/pr24171.sh: Same.
	* testsuite/dwz.tests/pr24173.sh: Same.
	* testsuite/dwz.tests/pr24174.sh: Same.
	* testsuite/dwz.tests/pr24341.sh: Same.
	* testsuite/dwz.tests/regular-o.sh: Same.
	* testsuite/dwz.tests/regular.sh: Same.
	* testsuite/dwz.tests/too-many-dies.sh: Same.
	* testsuite/dwz.tests/twice-hardlink.sh: Same.
	* testsuite/dwz.tests/twice-multifile.sh: Same.
	* testsuite/dwz.tests/twice.sh: Same.
	* testsuite/dwz.tests/two-files-too-many-dies-2.sh: Same.
	* testsuite/dwz.tests/two-files-too-many-dies.sh: Same.
	* testsuite/dwz.tests/version.sh: Same.

---
 testsuite/dwz.tests/devel-ignore-locus.sh          | 8 ++++----
 testsuite/dwz.tests/devel-ignore-size.sh           | 8 ++++----
 testsuite/dwz.tests/devel-trace.sh                 | 4 ++--
 testsuite/dwz.tests/dwz-tests.exp                  | 1 +
 testsuite/dwz.tests/dwz.sh                         | 4 ++--
 testsuite/dwz.tests/eu-strip-unstrip-multifile.sh  | 4 ++--
 testsuite/dwz.tests/eu-strip-unstrip.sh            | 2 +-
 testsuite/dwz.tests/gdb-add-index.sh               | 2 +-
 testsuite/dwz.tests/hardlink-multifile.sh          | 8 ++++----
 testsuite/dwz.tests/hardlink.sh                    | 6 +++---
 testsuite/dwz.tests/help.sh                        | 4 ++--
 testsuite/dwz.tests/illegal-option.sh              | 6 +++---
 testsuite/dwz.tests/low-mem.sh                     | 4 ++--
 testsuite/dwz.tests/multifile-name.sh              | 8 ++++----
 testsuite/dwz.tests/multifile-relative.sh          | 8 ++++----
 testsuite/dwz.tests/multifile.sh                   | 8 ++++----
 testsuite/dwz.tests/objcopy-remove-debug-abbrev.sh | 2 +-
 testsuite/dwz.tests/objcopy-strip-debug.sh         | 2 +-
 testsuite/dwz.tests/pr24171.sh                     | 4 ++--
 testsuite/dwz.tests/pr24173.sh                     | 2 +-
 testsuite/dwz.tests/pr24174.sh                     | 2 +-
 testsuite/dwz.tests/pr24341.sh                     | 6 +++---
 testsuite/dwz.tests/regular-o.sh                   | 4 ++--
 testsuite/dwz.tests/regular.sh                     | 4 ++--
 testsuite/dwz.tests/too-many-dies.sh               | 4 ++--
 testsuite/dwz.tests/twice-hardlink.sh              | 4 ++--
 testsuite/dwz.tests/twice-multifile.sh             | 6 +++---
 testsuite/dwz.tests/twice.sh                       | 4 ++--
 testsuite/dwz.tests/two-files-too-many-dies-2.sh   | 8 ++++----
 testsuite/dwz.tests/two-files-too-many-dies.sh     | 6 +++---
 testsuite/dwz.tests/version.sh                     | 4 ++--
 31 files changed, 74 insertions(+), 73 deletions(-)

diff --git a/testsuite/dwz.tests/devel-ignore-locus.sh b/testsuite/dwz.tests/devel-ignore-locus.sh
index 1cd0735..caa9d78 100644
--- a/testsuite/dwz.tests/devel-ignore-locus.sh
+++ b/testsuite/dwz.tests/devel-ignore-locus.sh
@@ -1,4 +1,4 @@
-cp ../two-typedef 1
+cp $execs/two-typedef 1
 
 cnt=$(readelf -wi 1 \
 	    | grep 'DW_AT_name.*: aaa' \
@@ -6,7 +6,7 @@ cnt=$(readelf -wi 1 \
 
 [ $cnt -eq 2 ]
 
-../dwz-for-test 1 2>/dev/null
+ $execs/dwz-for-test 1 2>/dev/null
 
 cnt=$(readelf -wi 1 \
 	    | grep 'DW_AT_name.*: aaa' \
@@ -14,9 +14,9 @@ cnt=$(readelf -wi 1 \
 
 [ $cnt -eq 2 ]
 
-cp ../two-typedef 1
+cp $execs/two-typedef 1
 
-../dwz-for-test --devel-ignore-locus --devel-ignore-size 1
+ $execs/dwz-for-test --devel-ignore-locus --devel-ignore-size 1
 
 cnt=$(readelf -wi 1 \
 	    | grep 'DW_AT_name.*: aaa' \
diff --git a/testsuite/dwz.tests/devel-ignore-size.sh b/testsuite/dwz.tests/devel-ignore-size.sh
index db1c3eb..5134043 100644
--- a/testsuite/dwz.tests/devel-ignore-size.sh
+++ b/testsuite/dwz.tests/devel-ignore-size.sh
@@ -1,4 +1,4 @@
-cp ../min 1
+cp $execs/min 1
 
 cnt=$(readelf -wi 1 \
 	    | grep '(DW_TAG_partial_unit' \
@@ -6,7 +6,7 @@ cnt=$(readelf -wi 1 \
 
 [ $cnt -eq 0 ]
 
-../dwz-for-test 1 2>/dev/null
+ $execs/dwz-for-test 1 2>/dev/null
 
 cnt=$(readelf -wi 1 \
 	    | grep '(DW_TAG_partial_unit' \
@@ -14,9 +14,9 @@ cnt=$(readelf -wi 1 \
 
 [ $cnt -eq 0 ]
 
-cp ../min 1
+cp $execs/min 1
 
-../dwz-for-test --devel-ignore-size 1
+ $execs/dwz-for-test --devel-ignore-size 1
 
 cnt=$(readelf -wi 1 \
 	    | grep '(DW_TAG_partial_unit' \
diff --git a/testsuite/dwz.tests/devel-trace.sh b/testsuite/dwz.tests/devel-trace.sh
index 7b3eb6b..1acea4e 100644
--- a/testsuite/dwz.tests/devel-trace.sh
+++ b/testsuite/dwz.tests/devel-trace.sh
@@ -1,5 +1,5 @@
-cp ../hello 1
+cp $execs/hello 1
 
-../dwz-for-test --devel-trace 1 2>/dev/null
+ $execs/dwz-for-test --devel-trace 1 2>/dev/null
 
 rm -f 1
diff --git a/testsuite/dwz.tests/dwz-tests.exp b/testsuite/dwz.tests/dwz-tests.exp
index 9bb8e96..3ef8690 100644
--- a/testsuite/dwz.tests/dwz-tests.exp
+++ b/testsuite/dwz.tests/dwz-tests.exp
@@ -3,6 +3,7 @@ set tests [find $srcdir/$subdir *.sh]
 set pwd [pwd]
 
 set env(PATH) $pwd/$srcdir/scripts:$::env(PATH)
+set env(execs) $pwd
 
 foreach test $tests {
     global runtests
diff --git a/testsuite/dwz.tests/dwz.sh b/testsuite/dwz.tests/dwz.sh
index ed49006..1cb16d2 100644
--- a/testsuite/dwz.tests/dwz.sh
+++ b/testsuite/dwz.tests/dwz.sh
@@ -1,7 +1,7 @@
-cp ../dwz-for-test 1
+cp $execs/dwz-for-test 1
 
 dwz 1
 
-smaller-than.sh 1 ../dwz-for-test
+smaller-than.sh 1 $execs/dwz-for-test
 
 rm -f 1
diff --git a/testsuite/dwz.tests/eu-strip-unstrip-multifile.sh b/testsuite/dwz.tests/eu-strip-unstrip-multifile.sh
index c09d6f5..afe0994 100644
--- a/testsuite/dwz.tests/eu-strip-unstrip-multifile.sh
+++ b/testsuite/dwz.tests/eu-strip-unstrip-multifile.sh
@@ -1,5 +1,5 @@
-cp ../hello 1
-cp ../hello 2
+cp $execs/hello 1
+cp $execs/hello 2
 
 eu-strip 1 -o 1.stripped -f 1.debug
 eu-strip 2 -o 2.stripped -f 2.debug
diff --git a/testsuite/dwz.tests/eu-strip-unstrip.sh b/testsuite/dwz.tests/eu-strip-unstrip.sh
index 45220db..ce3adad 100644
--- a/testsuite/dwz.tests/eu-strip-unstrip.sh
+++ b/testsuite/dwz.tests/eu-strip-unstrip.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 
 eu-strip 1 -o 1.stripped -f 1.debug
 
diff --git a/testsuite/dwz.tests/gdb-add-index.sh b/testsuite/dwz.tests/gdb-add-index.sh
index f7ca56b..5a91b23 100644
--- a/testsuite/dwz.tests/gdb-add-index.sh
+++ b/testsuite/dwz.tests/gdb-add-index.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 
 gdb-add-index 1
 
diff --git a/testsuite/dwz.tests/hardlink-multifile.sh b/testsuite/dwz.tests/hardlink-multifile.sh
index 91d25e3..160a7ed 100644
--- a/testsuite/dwz.tests/hardlink-multifile.sh
+++ b/testsuite/dwz.tests/hardlink-multifile.sh
@@ -1,13 +1,13 @@
-cp ../hello 1
+cp $execs/hello 1
 ln 1 2
-cp ../hello 3
+cp $execs/hello 3
 
 dwz -h -m 4 1 2 3
 
 hardlinks-p.sh 1 2
 
-smaller-than.sh 1 ../hello
-smaller-than.sh 3 ../hello
+smaller-than.sh 1 $execs/hello
+smaller-than.sh 3 $execs/hello
 
 [ "$(gnu-debugaltlink-name.sh 1)" = "4" ]
 [ "$(gnu-debugaltlink-name.sh 3)" = "4" ]
diff --git a/testsuite/dwz.tests/hardlink.sh b/testsuite/dwz.tests/hardlink.sh
index d928989..3a956b2 100644
--- a/testsuite/dwz.tests/hardlink.sh
+++ b/testsuite/dwz.tests/hardlink.sh
@@ -1,10 +1,10 @@
-cp ../hello 1
+cp $execs/hello 1
 ln 1 2
 
 dwz -h 1 2
 
-smaller-than.sh 1 ../hello
-smaller-than.sh 2 ../hello
+smaller-than.sh 1 $execs/hello
+smaller-than.sh 2 $execs/hello
 
 hardlinks-p.sh 1 2
 
diff --git a/testsuite/dwz.tests/help.sh b/testsuite/dwz.tests/help.sh
index 7eeb5a6..b4d5e28 100644
--- a/testsuite/dwz.tests/help.sh
+++ b/testsuite/dwz.tests/help.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 
 if dwz -? 1 2> dwz.err; status=$?; then
     true
@@ -8,6 +8,6 @@ fi
 
 grep -q "Usage:" dwz.err
 
-cmp 1 ../hello
+cmp 1 $execs/hello
 
 rm -f 1 dwz.err
diff --git a/testsuite/dwz.tests/illegal-option.sh b/testsuite/dwz.tests/illegal-option.sh
index 9c3f50d..f767f4c 100644
--- a/testsuite/dwz.tests/illegal-option.sh
+++ b/testsuite/dwz.tests/illegal-option.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 
 if dwz -x 1 2> dwz.err; status=$?; then
     true
@@ -9,7 +9,7 @@ fi
 grep -q ": invalid option -- 'x'" dwz.err
 grep -q "Usage:" dwz.err
 
-cmp 1 ../hello
+cmp 1 $execs/hello
 
 if dwz --x 1 2> dwz.err; status=$?; then
     true
@@ -20,6 +20,6 @@ fi
 grep -q ": unrecognized option '--x'" dwz.err
 grep -q "Usage:" dwz.err
 
-cmp 1 ../hello
+cmp 1 $execs/hello
 
 rm -f 1 dwz.err
diff --git a/testsuite/dwz.tests/low-mem.sh b/testsuite/dwz.tests/low-mem.sh
index 44be2a9..e75a198 100644
--- a/testsuite/dwz.tests/low-mem.sh
+++ b/testsuite/dwz.tests/low-mem.sh
@@ -1,7 +1,7 @@
-cp ../hello 1
+cp $execs/hello 1
 
 dwz -l0 1
 
-smaller-than.sh 1 ../hello
+smaller-than.sh 1 $execs/hello
 
 rm -f 1
diff --git a/testsuite/dwz.tests/multifile-name.sh b/testsuite/dwz.tests/multifile-name.sh
index c8381db..31e73f2 100644
--- a/testsuite/dwz.tests/multifile-name.sh
+++ b/testsuite/dwz.tests/multifile-name.sh
@@ -1,10 +1,10 @@
-cp ../hello 1
-cp ../hello 2
+cp $execs/hello 1
+cp $execs/hello 2
 
 dwz -m 3 -M /xxx/yyy/3 1 2
 
-smaller-than.sh 1 ../hello
-smaller-than.sh 2 ../hello
+smaller-than.sh 1 $execs/hello
+smaller-than.sh 2 $execs/hello
 
 [ "$(gnu-debugaltlink-name.sh 1)" = "/xxx/yyy/3" ]
 [ "$(gnu-debugaltlink-name.sh 2)" = "/xxx/yyy/3" ]
diff --git a/testsuite/dwz.tests/multifile-relative.sh b/testsuite/dwz.tests/multifile-relative.sh
index a34f8b2..7254206 100644
--- a/testsuite/dwz.tests/multifile-relative.sh
+++ b/testsuite/dwz.tests/multifile-relative.sh
@@ -1,10 +1,10 @@
-cp ../hello 1
-cp ../hello 2
+cp $execs/hello 1
+cp $execs/hello 2
 
 dwz -m $(pwd -P)/3 -r 1 2
 
-smaller-than.sh 1 ../hello
-smaller-than.sh 2 ../hello
+smaller-than.sh 1 $execs/hello
+smaller-than.sh 2 $execs/hello
 
 [ "$(gnu-debugaltlink-name.sh 1)" = "3" ]
 [ "$(gnu-debugaltlink-name.sh 2)" = "3" ]
diff --git a/testsuite/dwz.tests/multifile.sh b/testsuite/dwz.tests/multifile.sh
index 9bcbace..b5f6112 100644
--- a/testsuite/dwz.tests/multifile.sh
+++ b/testsuite/dwz.tests/multifile.sh
@@ -1,10 +1,10 @@
-cp ../hello 1
-cp ../hello 2
+cp $execs/hello 1
+cp $execs/hello 2
 
 dwz -m 3 1 2
 
-smaller-than.sh 1 ../hello
-smaller-than.sh 2 ../hello
+smaller-than.sh 1 $execs/hello
+smaller-than.sh 2 $execs/hello
 
 [ "$(gnu-debugaltlink-name.sh 1)" = "3" ]
 [ "$(gnu-debugaltlink-name.sh 2)" = "3" ]
diff --git a/testsuite/dwz.tests/objcopy-remove-debug-abbrev.sh b/testsuite/dwz.tests/objcopy-remove-debug-abbrev.sh
index 93fa04b..98ab12c 100644
--- a/testsuite/dwz.tests/objcopy-remove-debug-abbrev.sh
+++ b/testsuite/dwz.tests/objcopy-remove-debug-abbrev.sh
@@ -1,4 +1,4 @@
-objcopy --remove-section=.debug_abbrev ../hello 1
+objcopy --remove-section=.debug_abbrev $execs/hello 1
 
 cp 1 1.saved
 
diff --git a/testsuite/dwz.tests/objcopy-strip-debug.sh b/testsuite/dwz.tests/objcopy-strip-debug.sh
index 3aec669..043563b 100644
--- a/testsuite/dwz.tests/objcopy-strip-debug.sh
+++ b/testsuite/dwz.tests/objcopy-strip-debug.sh
@@ -1,4 +1,4 @@
-objcopy --strip-debug ../hello 1
+objcopy --strip-debug $execs/hello 1
 
 cp 1 1.saved
 
diff --git a/testsuite/dwz.tests/pr24171.sh b/testsuite/dwz.tests/pr24171.sh
index 5e1e9a8..0705489 100644
--- a/testsuite/dwz.tests/pr24171.sh
+++ b/testsuite/dwz.tests/pr24171.sh
@@ -1,5 +1,5 @@
-cp ../dw2-restrict 1
-cp ../dw2-restrict 2
+cp $execs/dw2-restrict 1
+cp $execs/dw2-restrict 2
 
 if dwz -m 3 1 2 2>dwz.err; status=$?; then
     true
diff --git a/testsuite/dwz.tests/pr24173.sh b/testsuite/dwz.tests/pr24173.sh
index 5ac78ee..908c219 100644
--- a/testsuite/dwz.tests/pr24173.sh
+++ b/testsuite/dwz.tests/pr24173.sh
@@ -1,4 +1,4 @@
-cp ../py-section-script 1
+cp $execs/py-section-script 1
 
 eu-strip -g -f 1.debug 1
 
diff --git a/testsuite/dwz.tests/pr24174.sh b/testsuite/dwz.tests/pr24174.sh
index 1044368..05e1e9c 100644
--- a/testsuite/dwz.tests/pr24174.sh
+++ b/testsuite/dwz.tests/pr24174.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 objcopy --compress-debug-sections 1
 if dwz 1 2>dwz.err; status=$?; then
    true
diff --git a/testsuite/dwz.tests/pr24341.sh b/testsuite/dwz.tests/pr24341.sh
index 972fbf4..5a433a0 100644
--- a/testsuite/dwz.tests/pr24341.sh
+++ b/testsuite/dwz.tests/pr24341.sh
@@ -1,4 +1,4 @@
-cp ../min 1
+cp $execs/min 1
 cp 1 2
 
 dwz -m 3 1 2
@@ -6,8 +6,8 @@ dwz -m 3 1 2
 cnt=$(readelf -S 3 | grep "\.debug_info" | wc -l)
 [ $cnt -eq 0 ]
 
-smaller-than.sh 1 ../min
-smaller-than.sh 2 ../min
+smaller-than.sh 1 $execs/min
+smaller-than.sh 2 $execs/min
 
 [ "$(gnu-debugaltlink-name.sh 1)" = "3" ]
 [ "$(gnu-debugaltlink-name.sh 2)" = "3" ]
diff --git a/testsuite/dwz.tests/regular-o.sh b/testsuite/dwz.tests/regular-o.sh
index 00b6a46..1416e90 100644
--- a/testsuite/dwz.tests/regular-o.sh
+++ b/testsuite/dwz.tests/regular-o.sh
@@ -1,8 +1,8 @@
-cp ../hello 1
+cp $execs/hello 1
 
 dwz 1 -o 2
 
-cmp 1 ../hello
+cmp 1 $execs/hello
 
 smaller-than.sh 2 1
 
diff --git a/testsuite/dwz.tests/regular.sh b/testsuite/dwz.tests/regular.sh
index eeab8f7..9d33153 100644
--- a/testsuite/dwz.tests/regular.sh
+++ b/testsuite/dwz.tests/regular.sh
@@ -1,7 +1,7 @@
-cp ../hello 1
+cp $execs/hello 1
 
 dwz 1
 
-smaller-than.sh 1 ../hello
+smaller-than.sh 1 $execs/hello
 
 rm -f 1
diff --git a/testsuite/dwz.tests/too-many-dies.sh b/testsuite/dwz.tests/too-many-dies.sh
index aa2639b..53a0f4b 100644
--- a/testsuite/dwz.tests/too-many-dies.sh
+++ b/testsuite/dwz.tests/too-many-dies.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 
 if dwz -L0 1 2>dwz.err; status=?; then
     true
@@ -11,6 +11,6 @@ fi
 
 [ $status -eq 1 ]
 
-cmp 1 ../hello
+cmp 1 $execs/hello
 
 rm -f 1 dwz.err
diff --git a/testsuite/dwz.tests/twice-hardlink.sh b/testsuite/dwz.tests/twice-hardlink.sh
index 207e18d..6ce5ee1 100644
--- a/testsuite/dwz.tests/twice-hardlink.sh
+++ b/testsuite/dwz.tests/twice-hardlink.sh
@@ -1,9 +1,9 @@
-cp ../hello 1
+cp $execs/hello 1
 ln 1 2
 
 dwz -h 1 2
 
-smaller-than.sh 1 ../hello
+smaller-than.sh 1 $execs/hello
 
 hardlinks-p.sh 1 2
 
diff --git a/testsuite/dwz.tests/twice-multifile.sh b/testsuite/dwz.tests/twice-multifile.sh
index a0d023a..6d612f0 100644
--- a/testsuite/dwz.tests/twice-multifile.sh
+++ b/testsuite/dwz.tests/twice-multifile.sh
@@ -1,10 +1,10 @@
-cp ../hello 1
+cp $execs/hello 1
 cp 1 2
 
 dwz 1 2
 
-smaller-than.sh 1 ../hello
-smaller-than.sh 2 ../hello
+smaller-than.sh 1 $execs/hello
+smaller-than.sh 2 $execs/hello
 
 cp 1 1.saved
 cp 2 2.saved
diff --git a/testsuite/dwz.tests/twice.sh b/testsuite/dwz.tests/twice.sh
index 4db798e..210a966 100644
--- a/testsuite/dwz.tests/twice.sh
+++ b/testsuite/dwz.tests/twice.sh
@@ -1,8 +1,8 @@
-cp ../hello 1
+cp $execs/hello 1
 
 dwz 1
 
-smaller-than.sh 1 ../hello
+smaller-than.sh 1 $execs/hello
 
 cp 1 1.saved
 
diff --git a/testsuite/dwz.tests/two-files-too-many-dies-2.sh b/testsuite/dwz.tests/two-files-too-many-dies-2.sh
index fa97a76..91b5ccc 100644
--- a/testsuite/dwz.tests/two-files-too-many-dies-2.sh
+++ b/testsuite/dwz.tests/two-files-too-many-dies-2.sh
@@ -1,5 +1,5 @@
-cp ../hello 1
-cp ../dwz-for-test 2
+cp $execs/hello 1
+cp $execs/dwz-for-test 2
 
 limit=$(readelf -wi 2 \
 	    | grep '(DW_TAG' \
@@ -16,7 +16,7 @@ else
     [ $status -eq 1 ]
 fi
 
-smaller-than.sh 1 ../hello
-cmp 2 ../dwz-for-test
+smaller-than.sh 1 $execs/hello
+cmp 2 $execs/dwz-for-test
 
 rm -f 1 2 dwz.err
diff --git a/testsuite/dwz.tests/two-files-too-many-dies.sh b/testsuite/dwz.tests/two-files-too-many-dies.sh
index 5d0485e..fb7d496 100644
--- a/testsuite/dwz.tests/two-files-too-many-dies.sh
+++ b/testsuite/dwz.tests/two-files-too-many-dies.sh
@@ -1,4 +1,4 @@
-cp ../hello 1
+cp $execs/hello 1
 cp 1 2
 if dwz -L0 1 2 2>dwz.err; status=$?; then
     true
@@ -15,7 +15,7 @@ else
     [ $status -eq 1 ]
 fi
 
-cmp 1 ../hello
-cmp 2 ../hello
+cmp 1 $execs/hello
+cmp 2 $execs/hello
 
 rm -f 1 2 dwz.err
diff --git a/testsuite/dwz.tests/version.sh b/testsuite/dwz.tests/version.sh
index 273eb3d..ccc4524 100644
--- a/testsuite/dwz.tests/version.sh
+++ b/testsuite/dwz.tests/version.sh
@@ -1,9 +1,9 @@
-cp ../hello 1
+cp $execs/hello 1
 
 dwz -v 1 2> dwz.err
 
 grep -q "dwz version" dwz.err
 
-cmp 1 ../hello
+cmp 1 $execs/hello
 
 rm -f 1 dwz.err