Workflow: Dispatch and Test runner workflow test #1

Testing the dispatcher and engine_test workflow for any bugs, the
changes on these files always need to be uploaded to github to test if
it is working correctly
This commit is contained in:
2025-11-05 13:26:23 +01:00
parent d819368962
commit 7625eecbd9
3 changed files with 87 additions and 0 deletions

65
.github/workflows/dispatcher.yml vendored Normal file
View File

@@ -0,0 +1,65 @@
name: Dispatcher
on:
push:
branches:
- '**' # minden branchre lefut
jobs:
detect-and-dispatch:
runs-on: self-hosted # (sajat rpi-on fusson)
steps:
- name: Detect project from branch name
id: detect
run: |
BRANCH_NAME=${GITHUB_REF##*/}
echo "Branch name: $BRANCH_NAME"
if [[ "$BRANCH_NAME" == Engine/* ]]; then
echo "project=Engine" >> $GITHUB_OUTPUT
elif [[ "$BRANCH_NAME" == Server/* ]]; then
echo "project=Server" >> $GITHUB_OUTPUT
elif [[ "$BRANCH_NAME" == UI/* ]]; then
echo "project=UI" >> $GITHUB_OUTPUT
else
echo "project=unknown" >> $GITHUB_OUTPUT
fi
- name: Trigger Engine tests
if: steps.detect.outputs.project == 'Engine'
uses: peter-evans/workflow-dispatch@v2
with:
workflow: "engine_test.yml"
ref: ${{ github.ref }}
- name: Trigger Server tests
if: steps.detect.outputs.project == 'Server'
uses: peter-evans/workflow-dispatch@v2
with:
workflow: "server_test.yml"
ref: ${{ github.ref }}
- name: Trigger UI tests
if: steps.detect.outputs.project == 'UI'
uses: peter-evans/workflow-dispatch@v2
with:
workflow: "ui_test.yml"
ref: ${{ github.ref }}
- name: Trigger all tests (main/master)
if: github.ref_name == 'main' || github.ref_name == 'master'
uses: peter-evans/workflow-dispatch@v2
with:
workflow: "engine_test.yml"
ref: ${{ github.ref }}
- uses: peter-evans/workflow-dispatch@v2
if: github.ref_name == 'main' || github.ref_name == 'master'
with:
workflow: "server_test.yml"
ref: ${{ github.ref }}
- uses: peter-evans/workflow-dispatch@v2
if: github.ref_name == 'main' || github.ref_name == 'master'
with:
workflow: "ui_test.yml"
ref: ${{ github.ref }}