Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/ci-java.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,9 @@ jobs:
name: Check style with Spotless
run: ./mvnw spotless:check -Pintegration-test

integration-test:
needs: build
uses: ./.github/workflows/integration-test.yml
with:
java-versions: '[8, 11, 17, 21]'

60 changes: 60 additions & 0 deletions .github/workflows/integration-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Integration Tests

on:
workflow_dispatch:
inputs:
java-versions:
description: 'JSON array of Java versions to test'
required: false
default: '[8, 11, 17, 21]'
workflow_call:
inputs:
java-versions:
description: 'JSON array of Java versions to test'
type: string
required: false
default: '[8, 11, 17, 21]'
schedule:
- cron: '0 3 * * 1-5'

jobs:
integration-test:
runs-on: ubuntu-latest
timeout-minutes: 120
strategy:
fail-fast: false
matrix:
java: ${{ fromJSON(inputs.java-versions || '[8, 11, 17, 21]') }}
name: Java ${{ matrix.java }} integration test
steps:
- uses: actions/checkout@v7
- name: Prepare multi-module build
run: git submodule update --init --recursive
# Every job gets its own Cloud Foundry on KinD, so the matrix can run in parallel.
# The action deploys the kind-deployment ref given in `ref`, so keep both on the same commit.
- name: Set up Cloud Foundry
uses: cloudfoundry/kind-deployment/.github/actions/setup-cf@8f0e3947abd716fc73d4787ce83e74ab73fb86a9
with:
ref: 8f0e3947abd716fc73d4787ce83e74ab73fb86a9
- name: Set up Java
uses: actions/setup-java@v5
with:
distribution: liberica
java-version: ${{ matrix.java }}
- name: Cache Maven packages
uses: actions/cache@v6
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Run integration tests
# CC_ADMIN_PASSWORD and UAA_ADMIN_SECRET are exported by setup-cf
env:
TEST_APIHOST: api.cf.127-0-0-1.nip.io
TEST_ADMIN_USERNAME: ccadmin
TEST_ADMIN_PASSWORD: ${{ env.CC_ADMIN_PASSWORD }}
TEST_ADMIN_CLIENTID: admin
TEST_ADMIN_CLIENTSECRET: ${{ env.UAA_ADMIN_SECRET }}
TEST_SKIPSSLVALIDATION: 'true'
TEST_QUOTAS_ROUTES_RESERVEDPORTS: '50'
run: ./mvnw -B -Pintegration-test test -Dgpg.skip
Loading