Skip to content

Commit ff9d49c

Browse files
loic425dbu
authored andcommitted
Add support for Symfony 8
1 parent 036c31a commit ff9d49c

4 files changed

Lines changed: 28 additions & 4 deletions

File tree

.github/workflows/test-application.yaml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,24 @@ jobs:
3232
- sqlite
3333
dependencies:
3434
- highest
35+
symfony-version:
36+
- '*'
3537
include:
3638
- php-version: '8.0'
3739
dependencies: lowest
40+
symfony-version: '*'
3841
db: sqlite
3942
- php-version: '8.0'
4043
dependencies: lowest
44+
symfony-version: '5.*'
4145
db: mysql
4246
- php-version: '8.0'
4347
dependencies: lowest
48+
symfony-version: '5.*'
49+
db: pgsql
50+
- php-version: '8.5'
51+
dependencies: lowest
52+
symfony-version: '8.*'
4453
db: pgsql
4554

4655
services:
@@ -73,13 +82,17 @@ jobs:
7382
with:
7483
php-version: ${{ matrix.php-version }}
7584
extensions: "pdo, pdo_sqlite, pdo_mysql, mysql, pdo_pgsql"
76-
tools: 'composer:v2'
85+
tools: 'composer:v2, flex'
7786

7887
- name: PHP 8.0 simple cache
7988
# Symfony 5 is not compatible with SimpleCache 3 but does not declare a conflict. Symfony 6 can not be installed on PHP 8.0.
8089
if: ${{ '8.0' == matrix.php-version }}
8190
run: composer require psr/simple-cache "^2.0" --no-update
8291

92+
- name: Symfony version
93+
if: matrix.symfony-version != '*'
94+
run: composer config extra.symfony.require ${{ matrix.symfony-version }}
95+
8396
- name: Install dependencies with Composer
8497
uses: ramsey/composer-install@v2
8598
with:

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
Changelog
22
=========
33

4+
2.0.3
5+
-----
6+
7+
* Allow installation with Symfony 8.
8+
* Test with PHP 8.5.
9+
410
2.0.2
511
-----
612

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@
3434
"ext-simplexml": "*",
3535
"psr/log": "^1 || ^2 || ^3",
3636
"phpcr/phpcr-api-tests": "2.1.25",
37-
"phpunit/phpunit": "^9.0",
38-
"symfony/cache": "^5.4 || ^6.2 || ^7.0",
37+
"phpunit/phpunit": "^9.6.16",
38+
"symfony/cache": "^5.4 || ^6.2 || ^7.0 || ^8.0",
3939
"phpstan/phpstan": "^2.0"
4040
},
4141
"autoload": {

tests/Tools/Console/InitDoctrineDbalCommandTest.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,12 @@ public function setUp(): void
7979
$this->application->setHelperSet($this->helperSet);
8080

8181
$command = new InitDoctrineDbalCommand();
82-
$this->application->add($command);
82+
83+
if (method_exists($this->application, 'addCommand')) {
84+
$this->application->addCommand($command);
85+
} else {
86+
$this->application->add($command);
87+
}
8388
}
8489

8590
/**

0 commit comments

Comments
 (0)