Skip to content

Commit

Permalink
Fix scala#5055: Run tests with Java 11
Browse files Browse the repository at this point in the history
  • Loading branch information
OlivierBlanvillain committed May 8, 2019
1 parent b34ea5d commit 942b45b
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,16 @@ pipeline:
- git submodule update --init --recursive --jobs 7
- ./project/scripts/sbt community-build/test

test_bootstrapped_java11:
group: test
image: lampepfl/dotty:2019-04-22
commands:
- export JAVA_HOME="/usr/lib/jvm/java-11-openjdk-amd64/"
- cp -R . /tmp/6/ && cd /tmp/6/
- ./project/scripts/sbt ";compile ;test"
# when:
# event: [ push, tag, deployment ]

test_sbt:
group: test
image: lampepfl/dotty:2019-04-22
Expand Down
7 changes: 7 additions & 0 deletions project/scripts/sbt
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,18 @@ set -e

CMD="${1:?Missing sbt command}"

if [ -z "$JAVA_HOME" ]; then
SET_JAVA_VERSION=""
else
SET_JAVA_VERSION="-java-home"
fi

# run sbt with the supplied arg
sbt -J-Xmx4096m \
-J-XX:ReservedCodeCacheSize=512m \
-J-XX:MaxMetaspaceSize=1024m \
-Ddotty.drone.mem=4096m \
-Dsbt.ivy.home=/var/cache/drone/ivy2 \
-no-colors \
"$SET_JAVA_VERSION" "$JAVA_HOME" \
"$CMD"

0 comments on commit 942b45b

Please sign in to comment.