dist: xenial

matrix:
  fast_finish: true
  include:
    - language: java
      jdk: openjdk8
      env: FRONT=false

    - language: java
      jdk: openjdk9
      env: FRONT=false

    - language: java
      jdk: openjdk10
      env: FRONT=false

    - language: java
      jdk: openjdk11
      env: FRONT=false

    - language: java
      jdk: openjdk-ea
      env: FRONT=false

    - language: node_js
      node_js: lts/*
      env: FRONT=true
      addons:
        apt:
          packages:
            - chromium-browser

    - language: node_js
      node_js: node
      env: FRONT=true
      addons:
        apt:
          packages:
            - chromium-browser

  allow_failures:
    - jdk: openjdk9
    - jdk: openjdk10
    - jdk: openjdk11
    - jdk: openjdk-ea

before_install:
  - if [[ $FRONT = 'true' ]]; then curl -o- -L https://yarnpkg.com/install.sh | bash -s; fi
  - if [[ $FRONT = 'true' ]]; then PATH=$HOME/.yarn/bin:$PATH; fi
  - if [[ $FRONT = 'true' ]]; then cd front; fi

dist: xenial

matrix:
  fast_finish: true
  include:
    - language: java
      jdk: openjdk8
      env: FRONT=false

    - language: java
      jdk: openjdk9
      env: FRONT=false

    - language: java
      jdk: openjdk10
      env: FRONT=false

    - language: java
      jdk: openjdk11
      env: FRONT=false

    - language: java
      jdk: openjdk12
      env: FRONT=false

    - language: java
      jdk: openjdk-ea
      env: FRONT=false

    - language: node_js
      node_js: lts/*
      env: FRONT=true
      addons:
        apt:
          packages:
            - chromium-browser

    - language: node_js
      node_js: node
      env: FRONT=true
      addons:
        apt:
          packages:
            - chromium-browser

  allow_failures:
    - jdk: openjdk9
    - jdk: openjdk10
    - jdk: openjdk11
    - jdk: openjdk12
    - jdk: openjdk-ea

before_install:
  - if [[ $FRONT = 'true' ]]; then curl -o- -L https://yarnpkg.com/install.sh | bash -s; fi
  - if [[ $FRONT = 'true' ]]; then PATH=$HOME/.yarn/bin:$PATH; fi
  - if [[ $FRONT = 'true' ]]; then cd front; fi

Add jdk12 to build matrix (ea is jdk13)
Add jdk12 to build matrix (ea is jdk13)
