From 3481761668b1a021255613432bb646ff8b8fb09b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20Andr=C3=A9?= Date: Mon, 13 Oct 2025 02:47:14 +0200 Subject: [PATCH 1/2] Debug driver test on CI --- .github/workflows/CI.yml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index c9eeb10..98c7aa5 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -49,8 +49,16 @@ jobs: strategy: fail-fast: false matrix: - php: ['8.2', '8.3', '8.4'] - browser: ['chromium', 'firefox', 'webkit'] + php: [ + #'8.2', + '8.3', + '8.4' + ] + browser: [ + 'chromium', + # 'firefox', + # 'webkit' + ] env: PLAYWRIGHT_BROWSER: ${{ matrix.browser }} @@ -64,7 +72,7 @@ jobs: with: php-version: ${{ matrix.php }} coverage: none - tools: composer, phpunit + tools: composer - name: Composer cache uses: actions/cache@v4 @@ -94,6 +102,10 @@ jobs: - name: Start Mink test server run: vendor/bin/mink-test-server > mink-test-server.log 2>&1 & shell: bash + + - name: Output server log (debug) + run: tail -n +50 mink-test-server.log || true + if: failure() - name: Wait for Mink test server to be ready run: | From 60c05dafc9a121d26e5ec1dba0863a3715227a47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20Andr=C3=A9?= Date: Mon, 13 Oct 2025 03:03:32 +0200 Subject: [PATCH 2/2] Reusable workflows --- .github/workflows/CI.yml | 47 +++++++++++++++------------------------- 1 file changed, 17 insertions(+), 30 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 98c7aa5..b4c7d7d 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -2,46 +2,33 @@ name: CI on: push: + branches: [ "*" ] pull_request: + branches: [ "*" ] + workflow_dispatch: + +permissions: + contents: read concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true jobs: - coding-standards: - name: Coding Standards (PHP 8.4) - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - name: PHP 8.4 - uses: shivammathur/setup-php@v2 - with: - php-version: '8.4' - coverage: none - tools: composer, phpstan, php-cs-fixer + cs: + uses: playwright-php/.github/.github/workflows/CS.yml@main + # with: + # php-version: '8.4' + # composer-validate: true + # php-cs-fixer-args: '--diff --dry-run' - - name: Composer cache - uses: actions/cache@v4 - with: - path: ~/.composer/cache - key: composer-${{ runner.os }}-${{ hashFiles('**/composer.lock') }} - restore-keys: composer-${{ runner.os }}- + sa: + uses: playwright-php/.github/.github/workflows/SA.yml@main + # with: + # php-version: '8.4' + # phpstan-args: 'analyse --no-progress --memory-limit=-1' - - name: Install deps (no dev-scripts) - run: composer install --no-interaction --prefer-dist --no-progress - - - name: PHPStan (max level) - run: phpstan analyse --no-progress - - - name: PHP-CS-Fixer (dry-run) - run: | - if [ -f .php-cs-fixer.php ]; then - php-cs-fixer fix --diff --dry-run - else - echo "No .php-cs-fixer.php; skipping." - fi tests: name: Tests (PHP ${{ matrix.php }} • ${{ matrix.browser }})