Update contributing docs to point to Maestro and reflect direct push … #216
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Browser Tests | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| permissions: | |
| contents: read | |
| jobs: | |
| tests: | |
| name: ${{ matrix.name }} | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - name: Livewire Kit | |
| kit: Livewire | |
| teams: false | |
| - name: React Kit | |
| kit: React | |
| teams: false | |
| - name: Svelte Kit | |
| kit: Svelte | |
| teams: false | |
| - name: Vue Kit | |
| kit: Vue | |
| teams: false | |
| - name: Livewire Teams Kit | |
| kit: Livewire | |
| teams: true | |
| - name: React Teams Kit | |
| kit: React | |
| teams: true | |
| - name: Svelte Teams Kit | |
| kit: Svelte | |
| teams: true | |
| - name: Vue Teams Kit | |
| kit: Vue | |
| teams: true | |
| steps: | |
| - name: Checkout Maestro | |
| uses: actions/checkout@v6 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: '8.4' | |
| extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite | |
| coverage: none | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: 22 | |
| - name: Install Composer Dependencies | |
| working-directory: orchestrator | |
| run: composer install --no-interaction --prefer-dist | |
| - name: Build ${{ matrix.name }} | |
| working-directory: orchestrator | |
| run: php artisan build --kit=${{ matrix.kit }}${{ matrix.teams && ' --teams' || '' }} | |
| - name: Copy Browser Test Bootstrap to Build | |
| run: cp -r browser_tests/bootstrap/* build/ | |
| - name: Copy Browser Test Suite to Build | |
| run: cp -r browser_tests/${{ matrix.teams && 'teams' || 'common' }}/* build/ | |
| - name: Install Build Composer Dependencies | |
| working-directory: build | |
| run: | | |
| composer remove --dev phpunit/phpunit --no-interaction --no-update | |
| composer require --dev pestphp/pest pestphp/pest-plugin-browser pestphp/pest-plugin-laravel --no-interaction | |
| - name: Install Build Node Dependencies | |
| working-directory: build | |
| run: npm install | |
| - name: Install Playwright | |
| working-directory: build | |
| run: npm install playwright | |
| - name: Get Playwright Version | |
| id: playwright-version | |
| working-directory: build | |
| run: echo "version=$(node -e "console.log(require('playwright/package.json').version)")" >> $GITHUB_OUTPUT | |
| - name: Cache Playwright Browsers | |
| uses: actions/cache@v5 | |
| id: playwright-cache | |
| with: | |
| path: ~/.cache/ms-playwright | |
| key: playwright-${{ runner.os }}-${{ steps.playwright-version.outputs.version }} | |
| - name: Install Playwright Browsers | |
| if: steps.playwright-cache.outputs.cache-hit != 'true' | |
| working-directory: build | |
| run: npx playwright install --with-deps | |
| - name: Install Playwright Dependencies | |
| if: steps.playwright-cache.outputs.cache-hit == 'true' | |
| run: npx playwright install-deps | |
| - name: Setup Environment | |
| working-directory: build | |
| run: | | |
| cp .env.example .env | |
| php artisan key:generate | |
| - name: Build Frontend Assets | |
| working-directory: build | |
| run: npm run build | |
| - name: Run Browser Tests | |
| working-directory: build | |
| run: php vendor/bin/pest --parallel |