Test with Symfony 8 #392
Workflow file for this run
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: Test application | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - '[0-9]+.x' | |
| - '[0-9]+.[0-9]+' | |
| - '[0-9]+.[0-9]+.x' | |
| jobs: | |
| test: | |
| name: 'PHP ${{ matrix.php-version }}, Database ${{ matrix.db }} ${{ matrix.dependencies }}' | |
| runs-on: ubuntu-latest | |
| env: | |
| SYMFONY_DEPRECATIONS_HELPER: ${{ matrix.symfony-deprecation-helper }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| php-version: | |
| - '8.0' | |
| - '8.1' | |
| - '8.2' | |
| - '8.3' | |
| - '8.4' | |
| - '8.5' | |
| db: | |
| - mysql | |
| - pgsql | |
| - sqlite | |
| dependencies: | |
| - highest | |
| symfony-version: | |
| - '*' | |
| include: | |
| - php-version: '8.0' | |
| dependencies: lowest | |
| symfony-version: '*' | |
| db: sqlite | |
| - php-version: '8.0' | |
| dependencies: lowest | |
| symfony-version: '5.*' | |
| db: mysql | |
| - php-version: '8.0' | |
| dependencies: lowest | |
| symfony-version: '5.*' | |
| db: pgsql | |
| - php-version: '8.5' | |
| dependencies: lowest | |
| symfony-version: '8.*' | |
| db: pgsql | |
| services: | |
| mysql: | |
| image: mysql:8.3 | |
| env: | |
| MYSQL_ROOT_PASSWORD: root | |
| MYSQL_DATABASE: phpcr_tests | |
| options: >- | |
| --health-cmd "mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=5 | |
| ports: | |
| - 3306:3306 | |
| postgres: | |
| image: postgres:13 | |
| env: | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: phpcr_tests | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd "pg_isready" --health-interval 10s --health-timeout 5s --health-retries 5 | |
| steps: | |
| - name: Checkout project | |
| uses: actions/checkout@v3 | |
| - name: Install and configure PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: ${{ matrix.php-version }} | |
| extensions: "pdo, pdo_sqlite, pdo_mysql, mysql, pdo_pgsql" | |
| tools: 'composer:v2, flex' | |
| - name: PHP 8.0 simple cache | |
| # Symfony 5 is not compatible with SimpleCache 3 but does not declare a conflict. Symfony 6 can not be installed on PHP 8.0. | |
| if: ${{ '8.0' == matrix.php-version }} | |
| run: composer require psr/simple-cache "^2.0" --no-update | |
| - name: Symfony version | |
| if: matrix.symfony-version != '*' | |
| run: composer config extra.symfony.require ${{ matrix.symfony-version }} | |
| - name: Install dependencies with Composer | |
| uses: ramsey/composer-install@v2 | |
| with: | |
| dependency-versions: ${{ matrix.dependencies }} | |
| composer-options: --prefer-dist | |
| - name: Get source version of phpcr-utils | |
| run: | | |
| rm -rf vendor/phpcr/phpcr-utils | |
| composer update phpcr/phpcr-utils --prefer-source | |
| - name: Prepare test config | |
| run: | | |
| php tests/generate_phpunit_config.php ${{ matrix.db }} | |
| - name: Execute test cases | |
| run: | | |
| vendor/bin/phpunit -c ${{ matrix.db }}.phpunit.xml |