Sha256: 95ba05d1cb43b527e3d101d7bc09cd99abf12f1a84e72ca69be1a778d3d4ba7e

Contents?: true

Size: 930 Bytes

Versions: 5

Compression:

Stored size: 930 Bytes

Contents

#!/usr/bin/env bash
set -eo pipefail

echo '--- testing rails 3.2'

echo '-- setting environment'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
RAILS_ENV=test
BUNDLE_GEMFILE="$DIR/Gemfile"
cd $DIR

echo '-- bundle install'
bundle --version
bundle install --quiet --gemfile="$DIR/Gemfile" --retry 2 --path vendor/bundle

echo '-- cypress install'
bundle exec ./bin/rails g cypress_dev:install --cypress_folder=cypress --install_cypress_with=npm --no-install-cypress-examples

echo '-- start rails server'
# make sure the server is not running
(kill -9 `cat tmp/pids/server.pid` || true )

bundle exec ./bin/rails server -p 5002 -e test &
sleep 2 # give rails a chance to start up correctly

echo '-- cypress run'
cp -fv ../cypress.json .
if [ -z $CYPRESS_RECORD_KEY ]
then
    node_modules/.bin/cypress run
else
    node_modules/.bin/cypress run --record
fi

echo '-- stop rails server'
kill -9 `cat tmp/pids/server.pid`

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
cypress-on-rails-1.3.0 spec/integrations/rails_3_2/test.sh
cypress-on-rails-1.2.1 spec/integrations/rails_3_2/test.sh
cypress-on-rails-1.2.0 spec/integrations/rails_3_2/test.sh
cypress-on-rails-1.1.1 spec/integrations/rails_3_2/test.sh
cypress-on-rails-1.1.0 spec/integrations/rails_3_2/test.sh