Skip to content

PiT 24.6.0.beta4 (lin=true win=true skip=true) latest-java_partial-auth #488

PiT 24.6.0.beta4 (lin=true win=true skip=true) latest-java_partial-auth

PiT 24.6.0.beta4 (lin=true win=true skip=true) latest-java_partial-auth #488

Workflow file for this run

name: PiT
run-name: PiT ${{ inputs.version }} (lin=${{inputs.linux}} win=${{inputs.windows}} skip=${{inputs.skipcurrent}}) ${{inputs.starters}}
on:
workflow_dispatch:
inputs:
version:
description: 'Version'
required: false
type: string
starters:
description: 'Starters to run, separated by comma'
required: false
type: string
skipcurrent:
description: 'Skip running tests in current version'
required: false
type: boolean
default: false
skipdev:
description: 'Skip running tests in dev mode'
required: false
type: boolean
default: false
debug:
description: 'Be verbose when running PiT steps'
required: false
type: boolean
default: false
linux:
description: 'Run build in linux runner'
required: false
type: boolean
default: true
windows:
description: 'Run build in windows runner'
required: false
type: boolean
default: false
generated:
description: 'Generate and run all supported start presets and archetypes'
required: false
type: boolean
default: false
demos:
description: 'Checkout and run all demos'
required: false
type: boolean
default: false
join:
description: 'Number of apps to run per container (default 1)'
required: false
type: choice
options: ["1", "2", "3", "4"]
default: "1"
jobs:
prepare:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set.outputs.matrix }}
steps:
- id: set
shell: bash
run: |
# COMPUTE MATRIX
echo "Computing matrix ..."
[ -z "${{secrets.GHTK}}" -o -z "${{secrets.TB_LICENSE}}" -o -z "${{secrets.SS_LICENSE}}" -o -z "${{secrets.CE_LICENSE}}" ] && exit 1
git clone -q https://${{secrets.GHTK}}@github.com/vaadin/platform-in-test-script.git pit
V="${{inputs.version}}"
W="${{inputs.windows}}"
L="${{inputs.linux}}"
[ true != "$L" -a true != "$W" ] && L=true
A="$A --starters=${{inputs.starters}}"
[ true = "${{inputs.generated}}" ] && A="$A --generated"
[ true = "${{inputs.demos}}" ] && A="$A --demos"
S=`./pit/scripts/pit/run.sh $A --list=${{inputs.join}}`
M='{"include":['
for i in `echo $S`; do
J='{"app":"'$i'"'
[ -n "$V" ] && J=$J',"version":"'$V'"'
[ true = "$W" ] && M=$M$J',"os":"windows"},'
[ true = "$L" ] && M=$M$J',"os":"ubuntu"},'
done
M=`echo $M | sed -e s/,$//`']}'
echo "$M"
echo "matrix=$M" >> $GITHUB_OUTPUT
run:
needs: prepare
strategy:
fail-fast: false
matrix: ${{fromJson(needs.prepare.outputs.matrix)}}
runs-on: ${{matrix.os}}-latest
steps:
- run: |
# TEST PARAMETERS
[ -z "${{matrix.app}}" ] && exit 1
echo "RUNNING TEST FOR ${{matrix.app}} APP"
shell: bash
- run: |
# INSTALL PIT
git clone https://${{secrets.GHTK}}@github.com/vaadin/platform-in-test-script.git pit
cd pit && git rev-parse --short HEAD
shell: bash
- run: |
# INSTALL LICENSE
mkdir -p ~/.vaadin/
echo '{"username":"'`echo ${{secrets.TB_LICENSE}} | cut -d / -f1`'","proKey":"'`echo ${{secrets.TB_LICENSE}} | cut -d / -f2`'"}' > ~/.vaadin/proKey
echo "${{secrets.SS_LICENSE}}" > ~/vaadin.spreadsheet.developer.license
shell: bash
- if: ${{ env.ACT }}
run: |
# LINUX LIBS (ACT)
# see https://github.com/browser-actions/setup-chrome/issues/240
sudo ./pit/scripts/pit/docker/setup.sh --lib-chrome
- uses: browser-actions/setup-chrome@latest
with:
chrome-version: stable
- uses: actions/setup-node@v4
with:
node-version: '18'
- uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- uses: stCarolas/setup-maven@v5
with:
maven-version: '3.9.0'
- run: |
# PIT TESTS ${{matrix.app}} ${{inputs.version}}
echo "${{toJSON(inputs)}}"
[ -n "${{inputs.version}}" ] && ARG="--version=${{inputs.version}}"
[ true = "${{inputs.skipcurrent}}" ] && ARG="$ARG --skip-current"
[ true = "${{inputs.skipdev}}" ] && ARG="$ARG --skip-dev"
[ true = "${{inputs.debug}}" ] && ARG="$ARG --debug"
./pit/scripts/pit/run.sh --path
CMD="./pit/scripts/pit/run.sh $ARG --starters=${{matrix.app}}"
# Output the PiT command to execute, so as we can run the same locally
echo "$CMD"
# Run PiT in test mode, so as we can copy and paste commands when reporting
$CMD --test
# Run PiT
$CMD
env:
GHTK: ${{secrets.GHTK}}
CE_LICENSE: ${{secrets.CE_LICENSE}}
OPENAI_TOKEN: ${{secrets.OPENAI_TOKEN}}
MAVEN_ARGS: ${{env.MAVEN_ARGS}}
shell: bash
- if: ${{ env.ACT }}
run: |
# WAIT (ACT)
echo "Keeping docker container running, push Ctrl-C to terminate ..."
read key
- if: ${{failure()}}
uses: actions/upload-artifact@v4
with:
name: failed-outputs-${{matrix.app}}
path: tmp/**/*.out
if-no-files-found: ignore
retention-days: 7