rework of the e2e test suites

This commit is contained in:
Codex Agent
2025-11-19 22:23:33 +01:00
parent 8d2075bdd2
commit 0127114e59
32 changed files with 1593 additions and 124 deletions

View File

@@ -48,3 +48,71 @@ jobs:
- name: Tests
run: ./vendor/bin/phpunit
ui:
runs-on: ubuntu-latest
env:
APP_URL: http://127.0.0.1:8000
E2E_GUEST_BASE_URL: http://127.0.0.1:8000
E2E_GUEST_EVENT_SLUG: pwa-demo-event
E2E_TENANT_EMAIL: hello@lumen-moments.demo
E2E_TENANT_PASSWORD: Demo1234!
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.4
tools: composer:v2
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'
- name: Install Node Dependencies
run: npm ci
- name: Install Composer Dependencies
run: composer install --no-interaction --prefer-dist --optimize-autoloader
- name: Build Assets
run: npm run build
- name: Prepare Environment
run: |
cp .env.example .env
php artisan key:generate
php artisan migrate:fresh --seed --force
php artisan tenant:add-dummy --email=$E2E_TENANT_EMAIL --password=$E2E_TENANT_PASSWORD --first_name=E2E --last_name=Tenant --address="CI Street 1" --phone="+491234567" --no-interaction
- name: Start Laravel Server
run: php artisan serve --host=127.0.0.1 --port=8000 > storage/logs/ci-server.log 2>&1 &
- name: Wait for Server
run: npx --yes wait-on@7 http://127.0.0.1:8000
- name: Install Playwright Browsers
run: npx playwright install --with-deps
- name: Provision Guest Demo Event
run: |
curl --fail -X POST http://127.0.0.1:8000/api/_testing/guest-events \
-H "Content-Type: application/json" \
-d '{"slug":"pwa-demo-event","name":"CI Guest Demo"}'
- name: UI Purchase Suite
run: npm run test:ui:purchase -- --reporter=dot
- name: UI Auth Suite
run: npm run test:ui:auth -- --reporter=dot
- name: UI Admin Suite
run: npm run test:ui:admin -- --reporter=dot
- name: UI Guest Suite
run: npm run test:ui:guest -- --reporter=dot