Skip to content

Commit

Permalink
updated for eggs
Browse files Browse the repository at this point in the history
  • Loading branch information
davidhassell committed Aug 9, 2021
1 parent b9ee821 commit d159a3f
Showing 1 changed file with 15 additions and 9 deletions.
24 changes: 15 additions & 9 deletions test_release
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
#!/bin/bash

# --------------------------------------------------------------------
# Install and run tests in ~/tmp
#
# Usage:
#
# $ ./test_release 1.8.9.0
# --------------------------------------------------------------------

set -x

if [[ ! $1 ]] ; then
echo "No version \$1 (e.g. 3.2.0)"
echo "Must set version as \$1 (e.g. 1.7)"
exit 1
fi

Expand All @@ -12,22 +20,20 @@ vn=$1
# Get the major.minor Python version
py=$(python -V | cut -d " " -f 2 | cut -d "." -f 1,2)

mkdir -p ~/tmp

cp dist/cfunits-$vn.tar.gz ~/tmp
cd ~/tmp
rm -fr ~/tmp/test ~/tmp/bin ~/tmp/lib ~/tmp/cfunits-$vn

tar zxvf cfunits-$vn.tar.gz
cd cfunits-$vn
python setup.py install --home=~/tmp

export PYTHONPATH=~/tmp/lib/python:~/tmp/lib/python/cfunits-${vn}-py${py}.egg:$PYTHONPATH
export PYTHONPATH=~/tmp/lib/python/cfunits-$vn-py$py.egg:$PYTHONPATH

#cd ~/tmp/lib/python/cfunits/test

cd ~/tmp/lib/python/cfunits-${vn}-py${py}.egg/cfunits/test
python setup.py install --home=~/tmp

cd ~/tmp/lib/python/cfunits-$vn-py$py.egg/cfunits/test
python run_tests.py
test_result_status=$?

set -x

exit $test_result_status

0 comments on commit d159a3f

Please sign in to comment.