]> wimlib.net Git - wimlib/blobdiff - tests/test-imagex
test-imagex-*: Set $srcdir correctly
[wimlib] / tests / test-imagex
index 85689e5deb44531c90147b3eb2656672f662dad4..fcbf5406fb2b4a2cc4eb5fcb3726d033db5da233 100755 (executable)
@@ -1,11 +1,12 @@
-#!/bin/sh
+#!/bin/bash
 
 # This script does some sanity testing of the 'imagex' program.  It by no means
 # tests every aspect of wimlib comprehensively.
 
 set -e
 cd tests
 
 # This script does some sanity testing of the 'imagex' program.  It by no means
 # tests every aspect of wimlib comprehensively.
 
 set -e
 cd tests
-srcdir=..
+srcdir="${srcdir:-.}/.."
+srcdir="$(cd $srcdir; pwd)"
 
 imagex() {
        echo "imagex $@"
 
 imagex() {
        echo "imagex $@"