adding cphalcon parser tests to ensure alignment #8
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: "Volt CI" | |
| on: | |
| push: | |
| paths-ignore: | |
| - '**.md' | |
| - '**.txt' | |
| pull_request: | |
| workflow_dispatch: | |
| permissions: {} | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/master' }} | |
| jobs: | |
| # PHP CodeSniffer + PHPStan inspection | |
| phpcs: | |
| name: "Validate code style" | |
| permissions: | |
| contents: read | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: true | |
| matrix: | |
| php: | |
| - '8.1' | |
| - '8.2' | |
| - '8.3' | |
| - '8.4' | |
| - '8.5' | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: "Setup PHP" | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php }} | |
| extensions: mbstring, ctype | |
| coverage: none | |
| ini-values: apc.enable_cli=on, session.save_path=/tmp | |
| tools: pecl | |
| env: | |
| COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Install development dependencies with Composer | |
| uses: ramsey/composer-install@v4 | |
| with: | |
| composer-options: "--prefer-dist" | |
| - name: "PHPCS" | |
| run: composer cs | |
| - name: "PHPStan" | |
| run: composer analyze | |
| tests: | |
| name: Unit tests | |
| needs: phpcs | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| php: | |
| - '8.1' | |
| - '8.2' | |
| - '8.3' | |
| - '8.4' | |
| - '8.5' | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php }} | |
| extensions: mbstring, ctype | |
| coverage: xdebug | |
| tools: composer:v2 | |
| env: | |
| COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Validate composer.json | |
| run: composer validate --no-check-all --no-check-publish | |
| - name: Install dependencies | |
| uses: ramsey/composer-install@v4 | |
| with: | |
| composer-options: "--prefer-dist" | |
| - name: Run tests | |
| run: composer test | |
| coverage: | |
| name: Code Coverage | |
| needs: tests | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: '8.5' | |
| extensions: mbstring, ctype | |
| coverage: xdebug | |
| tools: composer:v2 | |
| env: | |
| COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Install dependencies | |
| uses: ramsey/composer-install@v4 | |
| with: | |
| composer-options: "--prefer-dist" | |
| - name: Run tests with coverage | |
| run: composer test-coverage | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| files: ./tests/_output/coverage.xml | |
| fail_ci_if_error: false |