Skip to content

Instantly share code, notes, and snippets.

@jeffrydegrande
Created February 14, 2012 23:23
Show Gist options
  • Save jeffrydegrande/1831588 to your computer and use it in GitHub Desktop.
Save jeffrydegrande/1831588 to your computer and use it in GitHub Desktop.
#!/bin/bash
set -xe
if [ -f /var/lib/jenkins/.bash_profile ]; then
source /var/lib/jenkins/.bash_profile
fi
ruby -v
export LC_ALL=en_US.UTF-8
export DISPLAY=:99
export GIT_SSL_NO_VERIFY=1
export RAILS_ENV=test
export RSPEC_OPTS="--no-color --format progress --profile"
cp /var/lib/jenkins/canal-do-credito/database.yml ${WORKSPACE}/config/database.yml
dropdb canal_do_credito_test || true
createdb canal_do_credito_test -E UTF-8 -T template0
bundle install --without development
bundle exec rake db:migrate
bundle exec rake db:test:prepare
bundle exec rspec $RSPEC_OPTS spec
bundle exec cucumber features
echo $?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment