Add comprehensive developer tooling setup #9
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: tests | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| branches: | |
| - master | |
| jobs: | |
| ci: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: 8.4 | |
| tools: composer:v2 | |
| coverage: xdebug | |
| - name: Setup Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: "22" | |
| cache: "npm" | |
| - name: Cache Composer Dependencies | |
| uses: actions/cache@v4 | |
| with: | |
| path: vendor | |
| key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-composer- | |
| - name: Install Node Dependencies | |
| run: npm ci | |
| - name: Install Dependencies | |
| run: composer install --no-interaction --prefer-dist --optimize-autoloader | |
| - name: Build Assets | |
| run: npm run build | |
| - name: Copy Environment File | |
| run: cp .env.example .env | |
| - name: Generate Application Key | |
| run: php artisan key:generate | |
| - name: Run Larastan Static Analysis | |
| run: vendor/bin/phpstan analyse --memory-limit=2G | |
| - name: Run Rector Check | |
| run: vendor/bin/rector process --dry-run | |
| - name: Tests | |
| run: ./vendor/bin/pest |