diff --git a/.travis.yml b/.travis.yml index 5c0335e..553239e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,15 +1,26 @@ services: - memcache +bundler_args: --path=~/.bundle before_install: - - "export DISPLAY=:99.0" - - "sh -e /etc/init.d/xvfb start" + - "echo 'gem: --no-ri --no-rdoc' > ~/.gemrc" + - gem install bundler bundle_cache + - bundle_cache_install + - export DISPLAY=:99.0 + - sh -e /etc/init.d/xvfb start before_script: - psql -c 'create database appfab_test;' -U postgres - cp config/database-travis.yml config/database.yml - rake db:migrate RAILS_ENV=test +after_script: + - bundle_cache rvm: - 2.0.0 env: - - BUILD_TARGET=spec - - BUILD_TARGET=cucumber + global: + - AWS_S3_BUCKET=bundle-cache-us + - BUNDLE_ARCHIVE=appfab + - secure: HdqU0O47txQMZhQy2aXEQ514g7Bh01XRgOvINI+8+rCK+176rARzux0NIzVUaPYODcEvsAK/7PV6PQvFpLJ6GaA9QngASWWbNCF3Za/wZDjbUSyP73FSszfXzQK1QfHvs/vH1nPt8Ul7L4nnU2Z2dpoXXPvtB/HCnszpB6mlNdw= + matrix: + - BUILD_TARGET=spec + - BUILD_TARGET=cucumber script: rake $BUILD_TARGET diff --git a/Gemfile b/Gemfile index 9627dae..142fb9b 100644 --- a/Gemfile +++ b/Gemfile @@ -42,7 +42,7 @@ gem 'andand' # (because Rails' #pluck breaks a lot with joins) gem 'valium' -# Property API for plain classes +# Property API for plain classes (used for form objects) gem 'virtus' # activerecord extensions @@ -84,6 +84,9 @@ gem 'coffee-rails' gem 'turbolinks' gem 'jquery-turbolinks' +# speeds up Travis builds by caching the bundle +gem 'bundle_cache' + # Gems used only for assets and not required # in production environments by default. group :assets do diff --git a/Gemfile.lock b/Gemfile.lock index 66175ab..4a72d78 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -34,6 +34,10 @@ GEM compass (>= 0.12.0) sass (>= 3.2.0.alpha.95) arel (3.0.2) + aws-sdk (1.11.1) + json (~> 1.4) + nokogiri (>= 1.4.4) + uuidtools (~> 2.1) backports (3.3.3) bcrypt-ruby (3.1.1) better_errors (0.9.0) @@ -44,6 +48,10 @@ GEM bootstrap-sass (2.3.2.1) sass (~> 3.2) builder (3.0.4) + bundle_cache (0.0.5) + aws-sdk (>= 1.0.0) + bundler + bundler cancan (1.6.10) capybara (2.0.3) mime-types (>= 1.16) @@ -398,6 +406,7 @@ DEPENDENCIES better_errors binding_of_caller bootstrap-sass + bundle_cache cancan capybara (~> 2.0.3) coffee-rails