2021-04-05 10:02:27 +00:00
|
|
|
name: Validate Java e2e
|
2022-12-15 15:10:53 +00:00
|
|
|
|
2021-04-05 10:02:27 +00:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
- releases/*
|
|
|
|
paths-ignore:
|
|
|
|
- '**.md'
|
|
|
|
pull_request:
|
|
|
|
paths-ignore:
|
|
|
|
- '**.md'
|
2021-04-12 08:08:05 +00:00
|
|
|
schedule:
|
2023-03-09 12:49:35 +00:00
|
|
|
- cron: '0 */12 * * *'
|
2021-08-06 10:12:36 +00:00
|
|
|
workflow_dispatch:
|
2021-04-05 10:02:27 +00:00
|
|
|
jobs:
|
|
|
|
setup-java-major-versions:
|
|
|
|
name: ${{ matrix.distribution }} ${{ matrix.version }} (jdk-x64) - ${{ matrix.os }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2024-05-22 15:26:50 +00:00
|
|
|
os: [macos-13, windows-latest, ubuntu-latest]
|
2023-03-09 12:49:35 +00:00
|
|
|
distribution: [
|
|
|
|
'temurin',
|
|
|
|
'adopt',
|
|
|
|
'adopt-openj9',
|
|
|
|
'zulu',
|
|
|
|
'liberica',
|
|
|
|
'microsoft',
|
2023-03-21 09:32:38 +00:00
|
|
|
'semeru',
|
2023-09-20 11:22:11 +00:00
|
|
|
'corretto',
|
2024-09-05 19:04:24 +00:00
|
|
|
'dragonwell',
|
|
|
|
'sapmachine'
|
2023-03-09 12:49:35 +00:00
|
|
|
] # internally 'adopt-hotspot' is the same as 'adopt'
|
2024-05-22 15:26:50 +00:00
|
|
|
version: ['21', '11', '17']
|
2021-12-08 18:50:14 +00:00
|
|
|
exclude:
|
2023-03-09 12:49:35 +00:00
|
|
|
- distribution: microsoft
|
|
|
|
version: 8
|
2023-09-20 11:22:11 +00:00
|
|
|
- distribution: dragonwell
|
2024-05-22 15:26:50 +00:00
|
|
|
os: macos-13
|
2023-02-07 15:29:21 +00:00
|
|
|
include:
|
2023-03-09 12:49:35 +00:00
|
|
|
- distribution: oracle
|
2024-05-22 15:26:50 +00:00
|
|
|
os: macos-13
|
2023-03-09 12:49:35 +00:00
|
|
|
version: 17
|
|
|
|
- distribution: oracle
|
|
|
|
os: windows-latest
|
2023-05-08 09:48:02 +00:00
|
|
|
version: 20
|
2023-03-09 12:49:35 +00:00
|
|
|
- distribution: oracle
|
|
|
|
os: ubuntu-latest
|
2023-05-08 09:48:02 +00:00
|
|
|
version: 20
|
2023-09-20 11:22:11 +00:00
|
|
|
|
2021-04-05 10:02:27 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
java-version: ${{ matrix.version }}
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
|
|
|
setup-java-major-minor-versions:
|
|
|
|
name: ${{ matrix.distribution }} ${{ matrix.version }} (jdk-x64) - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2021-11-29 09:15:06 +00:00
|
|
|
distribution: ['temurin', 'zulu', 'liberica']
|
2021-04-05 10:02:27 +00:00
|
|
|
version:
|
2023-03-09 12:49:35 +00:00
|
|
|
- '11.0'
|
2024-05-22 15:26:50 +00:00
|
|
|
- '21.0'
|
2023-05-08 09:48:02 +00:00
|
|
|
- '17.0.7+7'
|
2023-02-07 15:29:21 +00:00
|
|
|
include:
|
2023-03-09 12:49:35 +00:00
|
|
|
- distribution: oracle
|
|
|
|
os: ubuntu-latest
|
2023-05-08 09:48:02 +00:00
|
|
|
version: '20.0.1'
|
2023-09-20 11:22:11 +00:00
|
|
|
- distribution: dragonwell
|
|
|
|
os: ubuntu-latest
|
|
|
|
version: '11.0'
|
|
|
|
- distribution: dragonwell
|
|
|
|
os: ubuntu-latest
|
|
|
|
version: '11.0.13+9'
|
2024-09-05 19:04:24 +00:00
|
|
|
- distribution: sapmachine
|
|
|
|
os: ubuntu-latest
|
|
|
|
version: '17.0.7'
|
2021-04-05 10:02:27 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
java-version: ${{ matrix.version }}
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
|
|
|
setup-java-check-latest:
|
|
|
|
name: ${{ matrix.distribution }} ${{ matrix.version }} - check-latest flag - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2024-09-05 19:04:24 +00:00
|
|
|
distribution:
|
|
|
|
['temurin', 'zulu', 'liberica', 'dragonwell', 'sapmachine']
|
2023-09-20 11:22:11 +00:00
|
|
|
exclude:
|
|
|
|
- distribution: dragonwell
|
|
|
|
os: macos-latest
|
2021-04-05 10:02:27 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
java-version: 11
|
|
|
|
check-latest: true
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "11" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
2021-05-17 13:33:21 +00:00
|
|
|
|
2022-09-08 13:26:54 +00:00
|
|
|
setup-java-multiple-jdks:
|
|
|
|
name: ${{ matrix.distribution }} ${{ matrix.version }} - multiple jdks - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2024-09-05 19:04:24 +00:00
|
|
|
distribution:
|
|
|
|
['temurin', 'zulu', 'liberica', 'dragonwell', 'sapmachine']
|
2023-09-20 11:22:11 +00:00
|
|
|
exclude:
|
|
|
|
- distribution: dragonwell
|
|
|
|
os: macos-latest
|
2022-09-08 13:26:54 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2022-09-08 13:26:54 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
java-version: |
|
|
|
|
11
|
|
|
|
17
|
|
|
|
- name: Verify Java env variables
|
|
|
|
run: |
|
|
|
|
$versionsArr = "11","17"
|
|
|
|
foreach ($version in $versionsArr)
|
|
|
|
{
|
|
|
|
$envName = "JAVA_HOME_${version}_${env:RUNNER_ARCH}"
|
|
|
|
$JavaVersionPath = [Environment]::GetEnvironmentVariable($envName)
|
2024-09-05 19:04:24 +00:00
|
|
|
if (-not (Test-Path "$JavaVersionPath")) {
|
2022-09-08 13:26:54 +00:00
|
|
|
Write-Host "$envName is not found"
|
|
|
|
exit 1
|
2024-09-05 19:04:24 +00:00
|
|
|
}
|
2022-09-08 13:26:54 +00:00
|
|
|
}
|
|
|
|
shell: pwsh
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "17" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
2021-04-05 10:02:27 +00:00
|
|
|
setup-java-ea-versions-zulu:
|
|
|
|
name: zulu ${{ matrix.version }} (jdk-x64) - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-minor-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2024-05-22 15:26:50 +00:00
|
|
|
os: [macos-13, windows-latest, ubuntu-latest]
|
2021-04-05 10:02:27 +00:00
|
|
|
version: ['17-ea', '15.0.0-ea.14']
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
java-version: ${{ matrix.version }}
|
|
|
|
distribution: zulu
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
2021-08-06 10:12:36 +00:00
|
|
|
setup-java-ea-versions-temurin:
|
|
|
|
name: temurin ${{ matrix.version }} (jdk-x64) - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-minor-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
|
|
|
version: ['17-ea']
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-08-06 10:12:36 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
java-version: ${{ matrix.version }}
|
|
|
|
distribution: temurin
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
2024-09-05 19:04:24 +00:00
|
|
|
setup-java-ea-versions-sapmachine:
|
|
|
|
name: sapmachine ${{ matrix.version }} (jdk-x64) - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-minor-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
|
|
|
version: ['17-ea', '21-ea']
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
java-version: ${{ matrix.version }}
|
|
|
|
distribution: sapmachine
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
2021-04-05 10:02:27 +00:00
|
|
|
setup-java-custom-package-type:
|
|
|
|
name: ${{ matrix.distribution }} ${{ matrix.version }} (${{ matrix.java-package }}-x64) - ${{ matrix.os }}
|
|
|
|
needs: setup-java-major-minor-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2024-05-22 15:26:50 +00:00
|
|
|
os: [macos-13, windows-latest, ubuntu-latest]
|
2024-09-05 19:04:24 +00:00
|
|
|
distribution: ['temurin', 'zulu', 'liberica', 'semeru', 'sapmachine']
|
2021-04-05 10:02:27 +00:00
|
|
|
java-package: ['jre']
|
2022-04-29 10:38:36 +00:00
|
|
|
version: ['17.0']
|
2021-04-05 10:02:27 +00:00
|
|
|
include:
|
|
|
|
- distribution: 'zulu'
|
|
|
|
java-package: jre+fx
|
2024-05-22 15:26:50 +00:00
|
|
|
version: '21'
|
2021-04-05 10:02:27 +00:00
|
|
|
os: ubuntu-latest
|
|
|
|
- distribution: 'zulu'
|
|
|
|
java-package: jdk+fx
|
2024-05-22 15:26:50 +00:00
|
|
|
version: '21.0'
|
2021-04-05 10:02:27 +00:00
|
|
|
os: ubuntu-latest
|
2021-11-29 09:15:06 +00:00
|
|
|
- distribution: 'liberica'
|
|
|
|
java-package: jdk+fx
|
2024-05-22 15:26:50 +00:00
|
|
|
version: '21'
|
2021-11-29 09:15:06 +00:00
|
|
|
os: ubuntu-latest
|
|
|
|
- distribution: 'liberica'
|
|
|
|
java-package: jre+fx
|
|
|
|
version: '11'
|
|
|
|
os: ubuntu-latest
|
2022-04-29 10:38:36 +00:00
|
|
|
- distribution: 'corretto'
|
|
|
|
java-package: jre
|
|
|
|
version: '8'
|
|
|
|
os: windows-latest
|
2021-04-05 10:02:27 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
java-version: ${{ matrix.version }}
|
|
|
|
java-package: ${{ matrix.java-package }}
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
2021-12-08 18:50:14 +00:00
|
|
|
# Only Liberica and Zulu provide x86
|
|
|
|
setup-java-x86:
|
|
|
|
name: ${{ matrix.distribution }} ${{ matrix.version }} (jdk-${{ matrix.architecture }}) - ${{ matrix.os }}
|
2021-04-05 10:02:27 +00:00
|
|
|
needs: setup-java-major-minor-versions
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2021-12-08 18:50:14 +00:00
|
|
|
# x86 is not supported on macOS
|
2021-04-05 10:02:27 +00:00
|
|
|
os: [windows-latest, ubuntu-latest]
|
2022-04-29 10:38:36 +00:00
|
|
|
distribution: ['liberica', 'zulu', 'corretto']
|
2021-04-05 10:02:27 +00:00
|
|
|
version: ['11']
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
java-version: ${{ matrix.version }}
|
2021-12-08 18:50:14 +00:00
|
|
|
architecture: 'x86'
|
2021-04-05 10:02:27 +00:00
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "${{ matrix.version }}" "${{ steps.setup-java.outputs.path }}"
|
2021-05-17 13:33:21 +00:00
|
|
|
shell: bash
|
2021-12-08 18:50:14 +00:00
|
|
|
|
2022-12-13 11:45:14 +00:00
|
|
|
setup-java-version-both-version-inputs-presents:
|
|
|
|
name: ${{ matrix.distribution }} version (should be from input) - ${{ matrix.os }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2023-03-09 12:49:35 +00:00
|
|
|
distribution: ['temurin', 'microsoft', 'corretto']
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ['.java-version', '.tool-versions']
|
2022-12-13 11:45:14 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Create .java-version file
|
|
|
|
shell: bash
|
2024-05-22 15:26:50 +00:00
|
|
|
run: echo "17" > .java-version
|
2024-03-12 13:45:42 +00:00
|
|
|
- name: Create .tool-versions file
|
|
|
|
shell: bash
|
2024-05-22 15:26:50 +00:00
|
|
|
run: echo "java 17" > .tool-versions
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
|
|
|
java-version: 11
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ${{matrix.java-version-file }}
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "11" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
|
|
|
setup-java-version-from-file-major-notation:
|
|
|
|
name: ${{ matrix.distribution }} version from file X - ${{ matrix.os }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2023-03-09 12:49:35 +00:00
|
|
|
distribution: ['temurin', 'zulu', 'liberica', 'microsoft', 'corretto']
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ['.java-version', '.tool-versions']
|
2022-12-13 11:45:14 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Create .java-version file
|
|
|
|
shell: bash
|
|
|
|
run: echo "11" > .java-version
|
2024-03-12 13:45:42 +00:00
|
|
|
- name: Create .tool-versions file
|
|
|
|
shell: bash
|
|
|
|
run: echo "java 11" > .tool-versions
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ${{matrix.java-version-file }}
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Verify Java
|
|
|
|
run: bash __tests__/verify-java.sh "11" "${{ steps.setup-java.outputs.path }}"
|
|
|
|
shell: bash
|
|
|
|
|
|
|
|
setup-java-version-from-file-major-minor-patch-notation:
|
|
|
|
name: ${{ matrix.distribution }} version from file X.Y.Z - ${{ matrix.os }}
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2023-03-09 12:49:35 +00:00
|
|
|
distribution: ['adopt', 'adopt-openj9', 'zulu']
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ['.java-version', '.tool-versions']
|
2022-12-13 11:45:14 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Create .java-version file
|
|
|
|
shell: bash
|
2024-05-22 15:26:50 +00:00
|
|
|
run: echo "17.0.10" > .java-version
|
2024-03-12 13:45:42 +00:00
|
|
|
- name: Create .tool-versions file
|
|
|
|
shell: bash
|
2024-05-22 15:26:50 +00:00
|
|
|
run: echo "java 17.0.10" > .tool-versions
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ${{matrix.java-version-file }}
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Verify Java
|
2024-05-22 15:26:50 +00:00
|
|
|
run: bash __tests__/verify-java.sh "17.0.10" "${{ steps.setup-java.outputs.path }}"
|
2022-12-13 11:45:14 +00:00
|
|
|
shell: bash
|
|
|
|
|
|
|
|
setup-java-version-from-file-major-minor-patch-with-dist:
|
2024-05-22 15:26:50 +00:00
|
|
|
name: ${{ matrix.distribution }} version from file 'openjdk64-17.0.10' - ${{ matrix.os }}
|
2022-12-13 11:45:14 +00:00
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, windows-latest, ubuntu-latest]
|
2023-03-09 12:49:35 +00:00
|
|
|
distribution: ['adopt', 'zulu', 'liberica']
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ['.java-version', '.tool-versions']
|
2022-12-13 11:45:14 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-12-01 10:16:32 +00:00
|
|
|
uses: actions/checkout@v4
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Create .java-version file
|
|
|
|
shell: bash
|
2024-05-22 15:26:50 +00:00
|
|
|
run: echo "openjdk64-17.0.10" > .java-version
|
2024-03-12 13:45:42 +00:00
|
|
|
- name: Create .tool-versions file
|
|
|
|
shell: bash
|
2024-05-22 15:26:50 +00:00
|
|
|
run: echo "java openjdk64-17.0.10" > .tool-versions
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: setup-java
|
|
|
|
uses: ./
|
|
|
|
id: setup-java
|
|
|
|
with:
|
|
|
|
distribution: ${{ matrix.distribution }}
|
2024-03-12 13:45:42 +00:00
|
|
|
java-version-file: ${{matrix.java-version-file }}
|
2022-12-13 11:45:14 +00:00
|
|
|
- name: Verify Java
|
2024-05-22 15:26:50 +00:00
|
|
|
run: bash __tests__/verify-java.sh "17.0.10" "${{ steps.setup-java.outputs.path }}"
|
2022-12-13 11:45:14 +00:00
|
|
|
shell: bash
|