diff --git a/.github/workflows/test-upcoming-symfony.yaml b/.github/workflows/test-upcoming-symfony.yaml deleted file mode 100644 index e94f57f777..0000000000 --- a/.github/workflows/test-upcoming-symfony.yaml +++ /dev/null @@ -1,48 +0,0 @@ -# OS: Linux; Symfony: the upcoming Symfony version (still in 'dev' or 'beta' or 'RC'); PHP: latest stable -name: "Tests - Upcoming Symfony version" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - name: "Symfony ${{ matrix.symfony-version }} / PHP ${{ matrix.php-version }}" - runs-on: 'ubuntu-latest' - continue-on-error: true - strategy: - matrix: - php-version: ['8.1'] - symfony-version: ['6.3'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer config extra.symfony.require "${{ matrix.symfony-version }}" - composer update --no-interaction --prefer-dist --optimize-autoloader || exit 0 - vendor/bin/simple-phpunit install || exit 0 - - - name: 'Run tests' - env: - SYMFONY_DEPRECATIONS_HELPER: 'max[total]=999999' - run: vendor/bin/simple-phpunit -v || exit 0 diff --git a/.github/workflows/tests-linux.yaml b/.github/workflows/tests-linux.yaml deleted file mode 100644 index 2942d5422e..0000000000 --- a/.github/workflows/tests-linux.yaml +++ /dev/null @@ -1,48 +0,0 @@ -# OS: Linux; Symfony: latest stable; PHP: all the commonly used versions supported by this bundle -name: "Tests - Linux" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - name: "PHP ${{ matrix.php-version }}" - runs-on: 'ubuntu-latest' - continue-on-error: false - strategy: - matrix: - php-version: ['8.1'] - symfony-version: ['6.2'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer config extra.symfony.require "${{ matrix.symfony-version }}" - composer update --no-interaction --prefer-dist --optimize-autoloader --prefer-stable - vendor/bin/simple-phpunit install - - - name: 'Run tests' - env: - SYMFONY_DEPRECATIONS_HELPER: 'max[indirect]=100000' - run: vendor/bin/simple-phpunit -v diff --git a/.github/workflows/tests-lowest-dependencies.yaml b/.github/workflows/tests-lowest-dependencies.yaml deleted file mode 100644 index 199b9a10d1..0000000000 --- a/.github/workflows/tests-lowest-dependencies.yaml +++ /dev/null @@ -1,45 +0,0 @@ -# OS: Linux; Symfony: lowest supported by this bundle; PHP: lowest supported by this bundle -name: "Tests - Lowest supported dependencies" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - runs-on: 'ubuntu-latest' - continue-on-error: false - strategy: - matrix: - php-version: ['8.0.2'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer update --no-interaction --prefer-dist --optimize-autoloader --prefer-stable --prefer-lowest - vendor/bin/simple-phpunit install - - - name: 'Run tests' - env: - SYMFONY_DEPRECATIONS_HELPER: 'max[indirect]=10&max[total]=27' - run: vendor/bin/simple-phpunit -v diff --git a/.github/workflows/tests-macos.yaml b/.github/workflows/tests-macos.yaml deleted file mode 100644 index 4f9a5ef685..0000000000 --- a/.github/workflows/tests-macos.yaml +++ /dev/null @@ -1,47 +0,0 @@ -# OS: macOS; Symfony: all stable versions; PHP: latest stable -name: "Tests - macOS" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - runs-on: 'macos-latest' - continue-on-error: false - strategy: - matrix: - php-version: ['8.1'] - symfony-version: ['6.2'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer config extra.symfony.require "${{ matrix.symfony-version }}" - composer update --no-interaction --prefer-dist --optimize-autoloader --prefer-stable - vendor/bin/simple-phpunit install - - - name: 'Run tests' - env: - SYMFONY_DEPRECATIONS_HELPER: 'max[indirect]=100000' - run: vendor/bin/simple-phpunit -v diff --git a/.github/workflows/tests-maintained-symfony.yaml b/.github/workflows/tests-maintained-symfony.yaml deleted file mode 100644 index 6af4049996..0000000000 --- a/.github/workflows/tests-maintained-symfony.yaml +++ /dev/null @@ -1,48 +0,0 @@ -# OS: Linux; Symfony: all the maintained Symfony versions (except 'current stable'); PHP: latest stable -name: "Tests - Maintained Symfony versions" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - name: "Symfony ${{ matrix.symfony-version }} / PHP ${{ matrix.php-version }}" - runs-on: 'ubuntu-latest' - continue-on-error: false - strategy: - matrix: - php-version: ['8.1'] - symfony-version: ['5.4', '6.0', '6.1'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer config extra.symfony.require "${{ matrix.symfony-version }}" - composer update --no-interaction --prefer-dist --optimize-autoloader - vendor/bin/simple-phpunit install - - - name: 'Run tests' - env: - SYMFONY_DEPRECATIONS_HELPER: 'max[total]=999999' - run: vendor/bin/simple-phpunit -v diff --git a/.github/workflows/tests-upcoming-php.yaml b/.github/workflows/tests-upcoming-php.yaml deleted file mode 100644 index ed04283fe2..0000000000 --- a/.github/workflows/tests-upcoming-php.yaml +++ /dev/null @@ -1,45 +0,0 @@ -# OS: Linux; Symfony: latest stable; PHP: upcoming (still unreleased) version -name: "Tests - Upcoming PHP version" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - runs-on: 'ubuntu-latest' - continue-on-error: true - strategy: - matrix: - php-version: ['8.2'] - symfony-version: ['6.2'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer config extra.symfony.require "${{ matrix.symfony-version }}" - composer update --no-interaction --prefer-dist --optimize-autoloader --prefer-stable --ignore-platform-req=php - vendor/bin/simple-phpunit install - - - name: 'Run tests' - run: vendor/bin/simple-phpunit -v || exit 0 diff --git a/.github/workflows/tests-windows.yaml b/.github/workflows/tests-windows.yaml deleted file mode 100644 index 908d7b0dd4..0000000000 --- a/.github/workflows/tests-windows.yaml +++ /dev/null @@ -1,47 +0,0 @@ -# OS: Windows; Symfony: latest stable; PHP: latest stable -name: "Tests - Windows" - -on: - pull_request: - push: - branches: - - '4.x' - -env: - fail-fast: true - -permissions: - contents: read - -jobs: - tests: - runs-on: 'windows-latest' - continue-on-error: false - strategy: - matrix: - php-version: ['8.1'] - symfony-version: ['6.2'] - steps: - - name: 'Checkout code' - uses: actions/checkout@v3 - - - name: 'Install PHP with extensions' - uses: shivammathur/setup-php@v2 - with: - coverage: none - php-version: ${{ matrix.php-version }} - tools: composer:v2 - extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 - ini-values: date.timezone=UTC - - - name: 'Install project dependencies' - run: | - composer require --no-progress --no-scripts --no-plugins symfony/flex - composer config extra.symfony.require "${{ matrix.symfony-version }}" - composer update --no-interaction --prefer-dist --optimize-autoloader --prefer-stable - vendor/bin/simple-phpunit install - - - name: 'Run tests' - env: - SYMFONY_DEPRECATIONS_HELPER: 'max[indirect]=100000' - run: vendor/bin/simple-phpunit -v diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml new file mode 100644 index 0000000000..1d0b76a749 --- /dev/null +++ b/.github/workflows/tests.yaml @@ -0,0 +1,110 @@ +name: Tests +on: + push: + branches: + - "4.x" + pull_request: + + +jobs: + maintained: + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + php_versions: ["8.1", "8.2"] + symfony_version: ["5.4", "6.0", "6.1", "6.2", "6.3"] + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v3 + + - name: Setup PHP, with composer and extensions + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php_versions }} + coverage: none + extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 + ini-values: date.timezone=UTC + + - name: symfony/flex is required to install the correct symfony version + run: | + composer global config --no-plugins allow-plugins.symfony/flex true + composer global require symfony/flex + + - name: Install dependencies + run: | + composer config extra.symfony.require "${{ matrix.symfony_version }}" + composer install + vendor/bin/simple-phpunit install + + - name: Run tests + env: + SYMFONY_DEPRECATIONS_HELPER: "weak" + run: vendor/bin/simple-phpunit + + + lowest: + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + php_versions: ["8.0.2"] + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v3 + + - name: Setup PHP, with composer and extensions + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php_versions }} + coverage: none + extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 + ini-values: date.timezone=UTC + + # We don't need `symfony/flex` and `composer config extra.symfony.require` here. + # `--prefer-lowest` will always install symfony 5.4 + - name: Install dependencies + run: | + composer update --no-progress --prefer-lowest + vendor/bin/simple-phpunit install + + - name: Run tests + env: + SYMFONY_DEPRECATIONS_HELPER: "weak" + run: vendor/bin/simple-phpunit + + + php-8_0: + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + php_versions: ["8.0"] + symfony_version: ["5.4", "6.0"] + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v3 + + - name: Setup PHP, with composer and extensions + uses: shivammathur/setup-php@v2 + with: + php-version: ${{ matrix.php_versions }} + coverage: none + extensions: mbstring, intl, pdo, pdo_sqlite, sqlite3 + ini-values: date.timezone=UTC + + - name: symfony/flex is required to install the correct symfony version + run: | + composer global config --no-plugins allow-plugins.symfony/flex true + composer global require symfony/flex + + - name: Install dependencies + run: | + composer config extra.symfony.require "${{ matrix.symfony_version }}" + composer install + vendor/bin/simple-phpunit install + + - name: Run tests + env: + SYMFONY_DEPRECATIONS_HELPER: "weak" + run: vendor/bin/simple-phpunit