language: java

matrix:
  include:
    ## https://docs.travis-ci.com/user/reference/trusty/
    ## has newer Maven
    - os: linux
      sudo: false
      dist: trusty
      jdk: oraclejdk8
      install: true
      env: FAILURES_ALLOWED=false
      addons:
        apt:
          packages:
          ## RPM
            - rpm
          ## DEB
            - fakeroot
    ## OpenJDK should work too, but TravisCI has no up2date Ubuntu-Image, makes it impossible to install OpenJFX
    - os: linux
      sudo: false
      dist: trusty
      jdk: oraclejdk9
      install: true
      env: FAILURES_ALLOWED=false
      addons:
        apt:
          packages:
          ## RPM
            - rpm
          ## DEB
            - fakeroot
    ## has older Maven
    - os: linux
      sudo: false
      dist: precise
      jdk: oraclejdk8
      env: FAILURES_ALLOWED=false
      addons:
        apt:
          packages:
          ## RPM
            - rpm
          ## DEB
            - fakeroot
    ## use different OSX versions
    ## OS X 10.11
    - os: osx
      osx_image: xcode8
      env: FAILURES_ALLOWED=false
    ## OS X 10.12
    - os: osx
      osx_image: xcode8.3
      env: FAILURES_ALLOWED=false
    ## OS X 10.12
    - os: osx
      osx_image: xcode9.2
      env: FAILURES_ALLOWED=false
  allow_failures:
    - env: FAILURES_ALLOWED=true

## maven-invoker-plugin is called after deploying javafx-maven-plugin into local repository, so change default-test-call to "install" (because its called at that maven-phase)
script:
  - mvn install -B

notifications:
  email: false
