Sha256: 1a4e4134598a72663009c6d97ef86bd49da77e68ea6ec6f07cf0f59b72465609

Contents?: true

Size: 1.14 KB

Versions: 188

Compression:

Stored size: 1.14 KB

Contents

#!/bin/sh

# script/test: Run test suite for application. Optionally pass in a path to an
#              individual test file to run a single test.


set -e

cd "$(dirname "$0")/.."

[ -z "$DEBUG" ] || set -x

export RACK_ROOT=$(cd "$(dirname $0)"/.. && pwd)

if [ "$RAILS_ENV" = "test" ] || [ "$RACK_ENV" = "test" ]; then
  # if executed and the environment is already set to `test`, then we want a
  # clean from scratch application. This almost always means a ci environment,
  # since we set the environment to `test` directly in `script/cibuild`.
  script/setup
else
  # if the environment isn't set to `test`, set it to `test` and update the
  # application to ensure all dependencies are met as well as any other things
  # that need to be up to date, like db migrations. The environement not having
  # already been set to `test` almost always means this is being called on it's
  # own from a `development` environment.
  export RAILS_ENV="test" RACK_ENV="test"

  script/update
fi

echo "===> Running tests..."

if [ -n "$1" ]; then
  # pass arguments to test call. This is useful for calling a single test.
  bin/rake test "$1"
else
  bin/rake test
fi

Version data entries

188 entries across 188 versions & 1 rubygems

Version Path
react_on_rails-13.4.0 script/test
react_on_rails-13.3.5 script/test
react_on_rails-13.3.4 script/test
react_on_rails-13.3.3 script/test
react_on_rails-13.3.2 script/test
react_on_rails-13.3.1 script/test
react_on_rails-13.3.0 script/test
react_on_rails-13.2.0 script/test
react_on_rails-13.1.0 script/test
react_on_rails-13.0.2 script/test
react_on_rails-13.0.1 script/test
react_on_rails-13.0.0 script/test
react_on_rails-13.0.0.beta.0 script/test
react_on_rails-12.6.0 script/test
react_on_rails-12.5.2 script/test
react_on_rails-12.5.1 script/test
react_on_rails-12.5.0 script/test
react_on_rails-12.4.0 script/test
react_on_rails-12.4.0.rc.0 script/test
react_on_rails-12.3.0 script/test