Skip to content

Commit

Permalink
Update to symfony7 (#70)
Browse files Browse the repository at this point in the history
* Update to symfony7

* Adjust CI and get released consolidation/config

* Adjust matrix

* 8.3

* Add token

* Omit phpunit update

* Cant use run-script

* Struggle

* syntax

* syntax

* matrix

* deps

* remove custom repo in composer.json

* Feedback

---------

Co-authored-by: Moshe Weitzman <[email protected]>
  • Loading branch information
larowlan and weitzman authored Apr 5, 2024
1 parent b0eeb8c commit df830bd
Show file tree
Hide file tree
Showing 3 changed files with 529 additions and 693 deletions.
25 changes: 13 additions & 12 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- name: Install PHP
uses: shivammathur/setup-php@v2
with:
php-version: 7.4
php-version: 8.2
coverage: none

- name: Install dependencies
Expand Down Expand Up @@ -56,6 +56,9 @@ jobs:
php-version: 8.1
coverage: none
extensions: intl
# https://github.com/composer/composer/issues/9084#issuecomment-752134788https://github.com/composer/composer/issues/9084#issuecomment-752134788
env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Install roave/backward-compatibility-check
run: |
Expand All @@ -82,7 +85,7 @@ jobs:
- windows-latest

php-version:
- "7.4"
- "8.2"

php-ini-values:
- assert.exception=1, zend.assertions=1
Expand All @@ -100,12 +103,7 @@ jobs:
dependencies: highest

- os: ubuntu-latest
php-version: "8.0"
dependencies: highest
php-ini-values: assert.exception=1, zend.assertions=1, opcache.enable=1, opcache.enable_cli=1, opcache.optimization_level=-1, opcache.jit_buffer_size=4096M, opcache.jit=1205

- os: ubuntu-latest
php-version: "8.1"
php-version: "8.3"
dependencies: highest
php-ini-values: assert.exception=1, zend.assertions=1, opcache.enable=1, opcache.enable_cli=1, opcache.optimization_level=-1, opcache.jit_buffer_size=4096M, opcache.jit=1205

Expand All @@ -120,6 +118,9 @@ jobs:
coverage: pcov
extensions: ${{ env.PHP_EXTENSIONS }}
ini-values: ${{ matrix.php-ini-values }}
# https://github.com/composer/composer/issues/9084#issuecomment-752134788https://github.com/composer/composer/issues/9084#issuecomment-752134788
env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Determine composer cache directory on Linux
if: matrix.os == 'ubuntu-latest'
Expand All @@ -139,15 +140,15 @@ jobs:
- name: Make sure composer.json is valid before we start modifyig it
run: composer validate
- name: Clear platform php configuration in case we need to update phpunit

- name: Clear platform php configuration
run: composer config --unset platform.php

- name: Update phpunit if dependencies are locked in case phpunit version in lock file is not compatible
if: matrix.dependencies == 'locked'
run: |
composer install --no-ansi --no-interaction --no-progress
composer update --no-ansi --no-interaction --no-progress phpunit/phpunit --with-all-dependencies
# composer update --no-ansi --no-interaction --no-progress phpunit/phpunit --with-all-dependencies

- name: Install lowest dependencies with composer
if: matrix.dependencies == 'lowest'
Expand All @@ -159,7 +160,7 @@ jobs:

- name: Run tests with phpunit
run: composer unit

- name: Publish code coverage to Codecov
if: matrix.os == 'ubuntu-latest' && matrix.php-version == '8.0'
run: bash <(curl -s https://codecov.io/bash)
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
},
"require": {
"php": ">=7.4",
"consolidation/config": "^1.2.1 || ^2",
"symfony/filesystem": "^5.4 || ^6",
"symfony/finder": "^5 || ^6"
"consolidation/config": "^1.2.1 || ^2 || ^3",
"symfony/filesystem": "^5.4 || ^6 || ^7",
"symfony/finder": "^5 || ^6 || ^7"
},
"require-dev": {
"php-coveralls/php-coveralls": "^2.4.2",
Expand All @@ -53,7 +53,7 @@
"optimize-autoloader": true,
"sort-packages": true,
"platform": {
"php": "7.4"
"php": "8.2.17"
}
},
"extra": {
Expand Down
Loading

0 comments on commit df830bd

Please sign in to comment.