language: ruby

rvm:
  - 1.8.7
  - 1.9.3
  - 2.0.0
  - jruby-18mode
  - jruby-19mode
  - rbx-18mode
  - rbx-19mode
  - ree

env:
  - ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
  - ACTIVE_RECORD_VERSION="~> 3.2.0"
  - ACTIVE_RECORD_VERSION="~> 3.1.0"

matrix:
  allow_failures:
    - rvm: rbx-18mode
    - rvm: rbx-19mode
    - env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
  exclude:
    - rvm: 1.8.7
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
    - rvm: jruby-18mode
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
    - rvm: rbx-18mode
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
    - rvm: ree
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"


before_script:
  - "psql -c 'create database pg_search_test;' -U postgres >/dev/null"

script: "bundle exec rspec spec"

language: ruby

rvm:
  - 1.8.7
  - 1.9.3
  - 2.0.0
  - jruby-18mode
  - jruby-19mode
  - rbx-18mode
  - rbx-19mode
  - ree

env:
  - ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
  - ACTIVE_RECORD_VERSION="~> 3.2.0"
  - ACTIVE_RECORD_VERSION="~> 3.1.0"

matrix:
  allow_failures:
    - rvm: rbx-18mode
    - rvm: rbx-19mode
    - rvm: jruby-19mode
    - env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
  exclude:
    - rvm: 1.8.7
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
    - rvm: jruby-18mode
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
    - rvm: rbx-18mode
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"
    - rvm: ree
      env: ACTIVE_RECORD_VERSION="~> 4.0.0.beta1"


before_script:
  - "psql -c 'create database pg_search_test;' -U postgres >/dev/null"

script: "bundle exec rspec spec"

Allow jruby-19mode to fail on Travis CI
Allow jruby-19mode to fail on Travis CI

Currently in Travis, jruby-19mode fails to correctly parse the gemspec
for will_paginate 3.0.4 for some unknown reason.

See https://travis-ci.org/Casecommons/pg_search/jobs/6197268 for an
example.
