You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ju...@apache.org on 2010/01/28 12:29:04 UTC
svn commit: r904041 -
/subversion/trunk/subversion/tests/cmdline/davautocheck.sh
Author: julianfoad
Date: Thu Jan 28 11:29:04 2010
New Revision: 904041
URL: http://svn.apache.org/viewvc?rev=904041&view=rev
Log:
Teach davautocheck.sh to run individual tests even when the build dir is not
the source dir.
* subversion/tests/cmdline/davautocheck.sh
Set ABS_SRCDIR to the root of the source tree that this script is in. When
not running a whole "make check", use ABS_SRCDIR rather than ABS_BUILDDIR
to locate the Python test script to run.
Modified:
subversion/trunk/subversion/tests/cmdline/davautocheck.sh
Modified: subversion/trunk/subversion/tests/cmdline/davautocheck.sh
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/tests/cmdline/davautocheck.sh?rev=904041&r1=904040&r2=904041&view=diff
==============================================================================
--- subversion/trunk/subversion/tests/cmdline/davautocheck.sh (original)
+++ subversion/trunk/subversion/tests/cmdline/davautocheck.sh Thu Jan 28 11:29:04 2010
@@ -144,12 +144,15 @@
say "Using '$APXS'..."
+# Find the source and build directories. The build dir can be found if it is
+# the current working dir or the source dir.
+pushd ${SCRIPTDIR}/../../../ > /dev/null
+ABS_SRCDIR=$(pwd)
+popd > /dev/null
if [ -x subversion/svn/svn ]; then
ABS_BUILDDIR=$(pwd)
-elif [ -x $SCRIPTDIR/../../svn/svn ]; then
- pushd $SCRIPTDIR/../../../ >/dev/null
- ABS_BUILDDIR=$(pwd)
- popd >/dev/null
+elif [ -x $ABS_SRCDIR/subversion/svn/svn ]; then
+ ABS_BUILDDIR=$ABS_SRCDIR
else
fail "Run this script from the root of Subversion's build tree!"
fi
@@ -368,7 +371,7 @@
pushd "$ABS_BUILDDIR/subversion/tests/cmdline/" >/dev/null
TEST="$1"
shift
- time "./${TEST}_tests.py" "--url=$BASE_URL" "$@"
+ time "$ABS_SRCDIR/subversion/tests/cmdline/${TEST}_tests.py" "--url=$BASE_URL" "$@"
r=$?
popd >/dev/null
fi