language: java
sudo: false

jdk:
  - oraclejdk8

env:
 - TERM=dumb

before_install:
 - cp gradle.properties.ci gradle.properties
 - export JAVA_OPTS="-Xmx384m -XX:+UseG1GC -XX:SoftRefLRUPolicyMSPerMB=0 -noverify"

script:
 - ./gradlew check
 - sh -c 'cd examples/write-behind-rxjava && mvn test'

after_success:
- ./gradlew coveralls uploadArchives

matrix:
  fast_finish: true

addons:
  apt:
    packages:
      - oracle-java8-installer

before_cache:
  - rm -f  $HOME/.gradle/caches/modules-2/modules-2.lock
  - rm -fr $HOME/.gradle/caches/*/plugin-resolution/
cache:
  directories:
    - $HOME/.m2
    - $HOME/.gradle/caches/
    - $HOME/.gradle/wrapper/

language: java
sudo: false

jdk:
  - oraclejdk8

env:
 - TERM=dumb

before_install:
 - cp gradle.properties.ci gradle.properties
 - export JAVA_OPTS="-Xmx384m -XX:+UseG1GC -XX:SoftRefLRUPolicyMSPerMB=0 -noverify"

script:
 - ./gradlew check -x :caffeine:slowCaffeineTest -x :caffeine:slowGuavaTest
 - travis_wait ./gradlew :caffeine:slowCaffeineTest
 - travis_wait ./gradlew :caffeine:slowGuavaTest
 - sh -c 'cd examples/write-behind-rxjava && mvn test'

after_success:
- ./gradlew coveralls uploadArchives

matrix:
  fast_finish: true

addons:
  apt:
    packages:
      - oracle-java8-installer

before_cache:
  - rm -f  $HOME/.gradle/caches/modules-2/modules-2.lock
  - rm -fr $HOME/.gradle/caches/*/plugin-resolution/
cache:
  directories:
    - $HOME/.m2
    - $HOME/.gradle/caches/
    - $HOME/.gradle/wrapper/

Increase CI timeout due to slow tests
Increase CI timeout due to slow tests
