83 lines
2.4 KiB
YAML
83 lines
2.4 KiB
YAML
name: Reusable - Smoke test
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
skip-windows:
|
|
type: boolean
|
|
required: false
|
|
cache-read-only:
|
|
type: boolean
|
|
required: false
|
|
no-build-cache:
|
|
type: boolean
|
|
required: false
|
|
secrets:
|
|
GRADLE_ENTERPRISE_ACCESS_KEY:
|
|
required: false
|
|
GE_CACHE_USERNAME:
|
|
required: false
|
|
GE_CACHE_PASSWORD:
|
|
required: false
|
|
|
|
jobs:
|
|
smoke-test:
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
os:
|
|
- windows-2019
|
|
- ubuntu-latest
|
|
smoke-test-suite:
|
|
- jetty
|
|
- liberty
|
|
- payara
|
|
- tomcat
|
|
- tomee
|
|
- websphere
|
|
- wildfly
|
|
- other
|
|
exclude:
|
|
- os: ${{ inputs.skip-windows && 'windows-2019' || '' }}
|
|
- os: windows-2019
|
|
smoke-test-suite: websphere
|
|
fail-fast: false
|
|
steps:
|
|
- name: Support long paths
|
|
run: git config --system core.longpaths true
|
|
if: matrix.os == 'windows-2019'
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- name: Set up JDK for running Gradle
|
|
uses: actions/setup-java@v2
|
|
with:
|
|
distribution: temurin
|
|
java-version: 17
|
|
|
|
- name: Test
|
|
env:
|
|
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
|
|
GE_CACHE_USERNAME: ${{ secrets.GE_CACHE_USERNAME }}
|
|
GE_CACHE_PASSWORD: ${{ secrets.GE_CACHE_PASSWORD }}
|
|
uses: gradle/gradle-build-action@v2
|
|
with:
|
|
arguments: ":smoke-tests:test -PsmokeTestSuite=${{ matrix.smoke-test-suite }}${{ inputs.no-build-cache && ' --no-build-cache' || '' }}"
|
|
# only push cache for one matrix option per OS since github action cache space is limited
|
|
cache-read-only: ${{ inputs.cache-read-only || matrix.smoke-test-suite != 'tomcat' }}
|
|
# gradle enterprise is used for the build cache
|
|
gradle-home-cache-excludes: caches/build-cache-1
|
|
|
|
- name: Upload jvm crash dump files if any
|
|
if: always()
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: javacore-smoke-test-${{ matrix.smoke-test-suite }}-${{ matrix.os }}
|
|
path: |
|
|
"**/hs_err_pid*.log"
|
|
"**/javacore.*.txt"
|
|
"**/Snap.*.trc"
|
|
"**/core.*.dmp"
|
|
"**/jitdump.*.dmp"
|
|
if-no-files-found: ignore
|