cache:
  directories:
    - $HOME/.m2

dist: xenial

env:
  - COMPILE_IMAGE_TAG=8-jdk-slim TEST_IMAGE_TAG=12-jdk-alpine

install: ./docker-mvnw $COMPILE_IMAGE_TAG --show-version --batch-mode -DskipTests=true -Dgpg.skip=true --activate-profiles sonatype-oss-release install

language: minimal

# Run the build in Docker to shield it from changes in the Travis environment:
services:
  - docker

script: ./docker-mvnw $TEST_IMAGE_TAG --batch-mode verify

cache:
  directories:
    - $HOME/.m2

dist: xenial

env:
  - BUILD_IMAGE_TAG=8-jdk-slim TEST_IMAGE_TAG=8-jdk-slim
  - BUILD_IMAGE_TAG=12-jdk-alpine TEST_IMAGE_TAG=12-jdk-alpine

install: ./docker-mvnw $BUILD_IMAGE_TAG --show-version --batch-mode -DskipTests=true -Dgpg.skip=true --activate-profiles sonatype-oss-release install

language: minimal

# Run the build in Docker to shield it from changes in the Travis environment:
services:
  - docker

script: ./docker-mvnw $TEST_IMAGE_TAG --batch-mode verify

Build and test with JDK 8 and JDK 12.
Build and test with JDK 8 and JDK 12.
