blob: 0aa4c2380afcda1f990f7fed779dec64b66a302b [file] [log] [blame]
on:
push:
branches:
- main
pull_request:
# Keeping this file separate as the dependencies check would use more
# repositories than needed this downstream check for GraalVM native image
# compilation.
name: downstream
env:
SHOWCASE_VERSION: 0.26.0
jobs:
# GraalVM job ensures the compatibility of GraaVM version
graalvm:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
graalvm: [22.3.0]
java: [11, 17]
steps:
- uses: actions/checkout@v3
- uses: stCarolas/setup-maven@v4
with:
maven-version: 3.8.1
- uses: ayltai/setup-graalvm@v1
with:
java-version: ${{matrix.java}}
# When a new version of native-maven-plugin fails to run in a downstream
# library, it's likely to be an incompatibility with the GraalVM version.
# In that case, you need to upgrade the Docker container used in the
# tests in the downstream repositories (not just this value below).
# Example: https://github.com/googleapis/testing-infra-docker/pull/195
graalvm-version: ${{matrix.graalvm}}
native-image: true
- name: Install maven modules
run: |
mvn install -B -ntp -DskipTests -Dclirr.skip -Dcheckstyle.skip
- name: Install showcase server
run: |
sudo mkdir -p /usr/src/showcase
sudo chown -R ${USER} /usr/src/
curl --location https://github.com/googleapis/gapic-showcase/releases/download/v${SHOWCASE_VERSION}/gapic-showcase-${SHOWCASE_VERSION}-linux-amd64.tar.gz --output /usr/src/showcase/showcase-${SHOWCASE_VERSION}-linux-amd64.tar.gz
cd /usr/src/showcase/
tar -xf showcase-*
./gapic-showcase run &
cd -
- name: Run Showcase tests with GraalVM
working-directory: showcase
run: |
java -version
sudo apt-get update -y
sudo apt-get install libxml2-utils
mvn test -Pnative,-showcase -Denforcer.skip=true -ntp -B