.travis.yml 1.3 KB
language: ruby
rvm:
# for 2.2 support we need to upgrade the pg gem
  - 2.1.6

sudo: false
addons:
  apt:
    packages:
      - po4a
      - iso-codes
      - tango-icon-theme
      - pidgin-data
      # for gem extensions
      - libmagickwand-dev
      - libpq-dev
      - libreadline-dev
      - libsqlite3-dev
      - libxslt1-dev

before_install:
  - gem env

# workaround for https://github.com/travis-ci/travis-ci/issues/4536
before_install:
  - export GEM_HOME=$PWD/vendor/bundle/ruby/2.1.0
  - gem install bundler
cache: bundler

before_script:
  - mkdir -p tmp/pids log
# workaround for plugins with Gemfile
  - perl -pi -e 's/cat .+ > \$gemfile/echo "source \\"https:\/\/rubygems.org\\"" > \$gemfile && cat \$source\/Gemfile >> \$gemfile/' script/noosfero-plugins
  - perl -pi -e 's/--local --quiet/install --jobs=3 --retry=3/' script/noosfero-plugins
  - script/noosfero-plugins disableall
  - bundle exec rake makemo &>/dev/null
# database
  - cp config/database.yml.travis config/database.yml
  - psql -c 'create database myapp_test;' -U postgres
  - bundle exec rake db:schema:load &>/dev/null
  - bundle exec rake db:migrate &>/dev/null

env:
  - TASK=test:units
  - TASK=test:functionals
  - TASK=test:integration
  - TASK=cucumber
  - TASK=selenium
  - TASK=test:noosfero_plugins

script:
  - bundle exec rake $TASK