Skip to content

Instantly share code, notes, and snippets.

@ralphos
Created April 17, 2014 01:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ralphos/10947916 to your computer and use it in GitHub Desktop.
Save ralphos/10947916 to your computer and use it in GitHub Desktop.
Travis
language: ruby
rvm:
- 1.9.3
bundler_args: --without development --deployment
cache:
- bundler
- apt
addons:
postgresql: "9.2"
firefox: "7.0.1"
before_script:
- "psql -c 'create database travis_ci_test;' -U postgres"
# Copy config files
- "cp config/database.yml.travis config/database.yml"
- "cp config/resque.example.yml config/resque.yml"
- "cp config/dps.example.yml config/dps.yml"
- "cp config/giftvouchers.example.yml config/giftvouchers.yml"
- "cp config/evoucher.example.yml config/evoucher.yml"
- "cp config/vii.example.yml config/vii.yml"
- "cp config/s3.yml.example config/s3.yml"
- "cp config/aprimo.example.yml config/aprimo.yml"
- "cp config/sphinx.example.yml config/sphinx.yml"
# Setup DB and start Sphinx
- "sudo apt-get install libaspell-dev openjdk-6-jdk gcc libxml2 libxml2-dev libxslt1-dev"
- "RAILS_ENV=test bundle exec rake db:create db:schema:load"
- "RAILS_ENV=test bundle exec rake ts:config --trace"
- "RAILS_ENV=test bundle exec rake ts:start --trace"
# Check Sphinx is running
- "ps aux | grep searchd"
before_install:
- "sudo apt-get install aspell libaspell-dev aspell-en"
- "gem install raspell -v '1.2.2'"
# Install Sphinx 0.9.9
- "wget http://sphinxsearch.com/files/archive/sphinx-0.9.9.tar.gz"
- "tar -zxvf sphinx-0.9.9.tar.gz"
- "sh -c 'cd sphinx-0.9.9 && wget http://snowball.tartarus.org/dist/libstemmer_c.tgz && tar xzf libstemmer_c.tgz && ./configure --with-libstemmer --with-iconv --with-mysql --with-pgsql --enable-id64 --quiet && make -j --quiet && sudo make install'"
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
services:
- redis-server
script:
- 'bundle exec rake rspec:$TEST_SUITE'
env:
- TEST_SUITE=models
- TEST_SUITE=requests_group_1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment