8 if [[ "$INSTANCE" == '' ]]; then
9 echo "Syntax: $0 <instance> [revision]"
14 if ! [[ -n "$WORKSPACE" ]]; then
15 echo "WORKSPACE environment variable not set"
20 txt="********** $1 **********"
21 printf "\n%*s%s\n\n" $((($COLUMNS-${#txt})/2)) "" "$txt"
29 echo -n "$(($SECONDS - $t0))s"
32 source /etc/profile.d/rvm.sh
35 title "Starting diagnostics"
40 if [[ "$REVISION" != '' ]]; then
41 git checkout $REVISION
44 cp -f /home/jenkins/diagnostics/arvados-workbench/$INSTANCE-application.yml $WORKSPACE/apps/workbench/config/application.yml
46 cd $WORKSPACE/apps/workbench
48 HOME="$GEMHOME" bundle install --no-deployment
50 if [[ ! -d tmp ]]; then
54 RAILS_ENV=diagnostics bundle exec rake TEST=test/diagnostics/pipeline_test.rb
58 if [[ "$REVISION" != '' ]]; then
62 if [[ "$ECODE" != "0" ]]; then
63 title "!!!!!! DIAGNOSTICS FAILED (`timer`) !!!!!!"
64 EXITCODE=$(($EXITCODE + $ECODE))
68 title "Diagnostics complete (`timer`)"