Files
cards/.github/workflows/tests.yml
Team3 dfcd3cb713
Some checks failed
Tests / headless (push) Has been cancelled
Tests / fenster-schnell (push) Has been cancelled
Tests / fenster-voll (push) Has been cancelled
Tests / balance (push) Has been cancelled
update
2026-09-22 13:23:02 +02:00

77 lines
2.9 KiB
YAML

name: Tests
on:
push:
pull_request:
schedule:
- cron: "0 3 * * *"
workflow_dispatch:
jobs:
headless:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Godot laden
run: |
curl -sSL -o godot.zip https://github.com/godotengine/godot/releases/download/4.7.2-stable/Godot_v4.7.2-stable_linux.x86_64.zip
unzip -q godot.zip
mv Godot_v4.7.2-stable_linux.x86_64 godot
chmod +x godot
- name: Statische Prüfung und Tests
run: ./tests/run_headless.sh ./godot
fenster-schnell:
if: github.event_name != 'schedule'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Godot und Xvfb laden
run: |
curl -sSL -o godot.zip https://github.com/godotengine/godot/releases/download/4.7.2-stable/Godot_v4.7.2-stable_linux.x86_64.zip
unzip -q godot.zip
mv Godot_v4.7.2-stable_linux.x86_64 godot
chmod +x godot
sudo apt-get update -qq && sudo apt-get install -y -qq xvfb libgl1 libegl1
- name: Import
run: ./godot --headless --path . --import || true
- name: Fenster-Test (schnell)
run: DINGER_FAST=1 xvfb-run -a --server-args="-screen 0 1280x800x24" ./godot --path . tests/ui_test.tscn 2>&1 | tee fenster.log | grep -E "FEHLER|Prüfungen" || true
- name: Ergebnis
run: grep -q " 0 fehlgeschlagen" fenster.log
fenster-voll:
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Godot und Xvfb laden
run: |
curl -sSL -o godot.zip https://github.com/godotengine/godot/releases/download/4.7.2-stable/Godot_v4.7.2-stable_linux.x86_64.zip
unzip -q godot.zip
mv Godot_v4.7.2-stable_linux.x86_64 godot
chmod +x godot
sudo apt-get update -qq && sudo apt-get install -y -qq xvfb libgl1 libegl1
- name: Import
run: ./godot --headless --path . --import || true
- name: Fenster-Test (voll)
run: xvfb-run -a --server-args="-screen 0 1280x800x24" ./godot --path . tests/ui_test.tscn 2>&1 | tee fenster.log | grep -E "FEHLER|Prüfungen" || true
- name: Ergebnis
run: grep -q " 0 fehlgeschlagen" fenster.log
balance:
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Godot laden
run: |
curl -sSL -o godot.zip https://github.com/godotengine/godot/releases/download/4.7.2-stable/Godot_v4.7.2-stable_linux.x86_64.zip
unzip -q godot.zip
mv Godot_v4.7.2-stable_linux.x86_64 godot
chmod +x godot
- name: Import
run: ./godot --headless --path . --import || true
- name: Balance messen
run: ./godot --headless --path . -s tests/simulate.gd 2>&1 | grep -E "Siege|Dauer"