language: ruby
services:
  - mysql
  - redis
rvm:
  - "1.9.3"
env:
  - DB=sqlite
  - DB=mysql
  - DB=postgresql
script:
  - bundle exec rspec spec
before_script:
  - cp config/database.yml.dist config/database.yml
  - cp config/initializers/sugar.rb.dist config/initializers/sugar.rb
  - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database sugar_test;'; fi"
  - sh -c "if [ '$DB' = 'postgresql' ]; then psql -c 'create database sugar_test' -U postgres; fi"
  - sh -c "if [ '$DB' = 'sqlite' ]; then bundle exec rake db:create; fi"
  - rake db:migrate

language: ruby
services:
  - mysql
  - redis
rvm:
  - "1.9.3"
env:
  - DB=sqlite
  - DB=mysql
  - DB=postgresql
script:
  - bundle exec rspec spec
before_script:
  - cp config/database.yml.dist config/database.yml
  - cp config/initializers/sugar.rb.dist config/initializers/sugar.rb
  - sh -c "if [ '$DB' = 'mysql' ]; then mysql -e 'create database sugar_test;'; fi"
  - sh -c "if [ '$DB' = 'postgresql' ]; then psql -c 'create database sugar_test' -U postgres; fi"
  - sh -c "if [ '$DB' = 'sqlite' ]; then bundle exec rake db:create; fi"
  - rake db:schema:load

Load schema instead of migrate on Travis build
Load schema instead of migrate on Travis build
