tests/testlib/pythonpath.sh
author Anton Shestakov <av6@dwimlabs.net>
Wed, 04 Mar 2020 16:05:28 +0100
branchstable
changeset 5147 83b607a9296d
parent 4336 33fc61e5e119
child 5316 277b45cf0dda
permissions -rw-r--r--
compat: officialy drop compatibility with mercurial 4.5

# utility to setup pythonpath to point into the tested repository

export SRCDIR="`dirname $TESTDIR`"
if [ -n "$PYTHONPATH" ]; then
    export HGTEST_ORIG_PYTHONPATH=$PYTHONPATH
    if uname -o | grep -q Msys; then
        export PYTHONPATH="$SRCDIR;$PYTHONPATH"
    else
        export PYTHONPATH=$SRCDIR:$PYTHONPATH
    fi
else
    export PYTHONPATH=$SRCDIR
fi