File tree Expand file tree Collapse file tree 14 files changed +93
-46
lines changed Expand file tree Collapse file tree 14 files changed +93
-46
lines changed Original file line number Diff line number Diff line change @@ -22,16 +22,22 @@ jobs:
22
22
- ' 6.1.*'
23
23
- ' 6.2.*'
24
24
- ' 7.0.*'
25
+ doctrine-orm-versions :
26
+ - ' ^2.17'
27
+ - ' ^3.0'
25
28
exclude :
26
29
- php : ' 8.1'
27
30
symfony-versions : ' 7.0.*'
31
+ - doctrine-orm-versions : ' ^3.0'
32
+ symfony-versions : ' 4.4.*'
28
33
include :
29
34
- description : ' Log Code Coverage'
30
35
php : ' 8.2'
31
36
coverage : ' xdebug'
37
+ doctrine-orm-versions : ' ^3.0'
32
38
symfony-versions : ' ^7.0'
33
39
34
- name : PHP ${{ matrix.php }} ${{ matrix.description }}
40
+ name : PHP ${{ matrix.php }} Symfony ${{ matrix.symfony-versions }} Doctrine ${{ matrix.doctrine-orm-versions }} ${{ matrix.description }}
35
41
steps :
36
42
- name : Checkout
37
43
uses : actions/checkout@v2
66
72
run : |
67
73
composer require symfony/dependency-injection:${{ matrix.symfony-versions }} --no-update --no-scripts
68
74
composer require symfony/http-kernel:${{ matrix.symfony-versions }} --no-update --no-scripts
75
+ composer require doctrine/orm:${{ matrix.doctrine-orm-versions }} --no-update --no-scripts
69
76
composer require --dev symfony/console:${{ matrix.symfony-versions }} --no-update --no-scripts
70
77
composer require --dev symfony/property-access:${{ matrix.symfony-versions }} --no-update --no-scripts
71
78
80
87
run : vendor/bin/phpunit --coverage-clover=coverage.xml
81
88
if : matrix.coverage == 'xdebug'
82
89
83
- - name : Run codecov
84
- uses : codecov/codecov-action@v1
90
+ - name : Upload coverage reports to Codecov
85
91
if : matrix.coverage == 'xdebug'
92
+ uses : codecov/codecov-action@v4.0.1
86
93
with :
87
- file : ' ./coverage.xml'
88
- fail_ci_if_error : true
94
+ token : ${{ secrets.CODECOV_TOKEN }}
Original file line number Diff line number Diff line change 5
5
/package-lock.json
6
6
/node_modules /
7
7
/.idea /
8
+ /coverage
9
+ /clover.xml
Original file line number Diff line number Diff line change 29
29
"require" : {
30
30
"php" : " ^7.4 || ^8.0" ,
31
31
"behat/behat" : " ^3.0" ,
32
- "doctrine/orm" : " ^2.0" ,
32
+ "doctrine/orm" : " ^2.0 || ^3.0 " ,
33
33
"doctrine/doctrine-bundle" : " ^2.0" ,
34
34
"doctrine/doctrine-fixtures-bundle" : " ^3.0" ,
35
35
"doctrine/doctrine-migrations-bundle" : " ^3.0" ,
36
36
"theofidry/alice-data-fixtures" : " ^1.0" ,
37
37
"symfony/dependency-injection" : " ^4.4 || ^5.4 || ^6.0 || ^7.0" ,
38
- "symfony/http-kernel" : " ^4.4 || ^5.4 || ^6.0 || ^7.0"
38
+ "symfony/http-kernel" : " ^4.4 || ^5.4 || ^6.0 || ^7.0" ,
39
+ "doctrine/dbal" : " ^2.0 || ^3.0"
39
40
},
40
41
"require-dev" : {
41
42
"phpstan/phpstan" : " ^1.2" ,
42
43
"phpunit/phpunit" : " ^9.5" ,
43
44
"slevomat/coding-standard" : " ^7.0" ,
44
45
"squizlabs/php_codesniffer" : " ^3.6" ,
45
46
"symfony/console" : " ^4.4 || ^5.4 || ^6.0 || ^7.0" ,
46
- "symfony/property-access" : " ^4.4 || ^5.4 || ^6.0 || ^7.0"
47
+ "symfony/property-access" : " ^4.4 || ^5.4 || ^6.0 || ^7.0" ,
48
+ "symplify/config-transformer" : " ^12.3"
47
49
},
48
50
"autoload" : {
49
51
"psr-4" : {
Original file line number Diff line number Diff line change @@ -12,3 +12,5 @@ parameters:
12
12
message : ' #Offset (.*)? does not exist on array\{(.*)?\}.#'
13
13
count : 1
14
14
path : ./src/Database/Manager/SqliteDatabaseManager.php
15
+ -
16
+ identifier : missingType.iterableValue
Original file line number Diff line number Diff line change @@ -3,6 +3,5 @@ includes:
3
3
4
4
parameters :
5
5
level : max
6
- checkMissingIterableValueType : false
7
6
paths :
8
7
- src/
Original file line number Diff line number Diff line change @@ -108,9 +108,9 @@ private function adaptDatabaseSchemaToSqlite(Schema $schema): void
108
108
{
109
109
foreach ($ schema ->getTables () as $ table ) {
110
110
foreach ($ table ->getColumns () as $ column ) {
111
- if ($ column ->hasCustomSchemaOption ('collation ' )) {
112
- $ column ->setCustomSchemaOptions (array_diff_key (
113
- $ column ->getCustomSchemaOptions (),
111
+ if ($ column ->hasPlatformOption ('collation ' )) {
112
+ $ column ->setPlatformOptions (array_diff_key (
113
+ $ column ->getPlatformOptions (),
114
114
['collation ' => true ]
115
115
));
116
116
}
Original file line number Diff line number Diff line change @@ -29,8 +29,8 @@ public function registerBundles(): iterable
29
29
30
30
public function registerContainerConfiguration (LoaderInterface $ loader ): void
31
31
{
32
- $ loader ->load (__DIR__ . '/config/doctrine.yml ' );
33
- $ loader ->load (__DIR__ . '/config/doctrine_migrations.yml ' );
32
+ $ loader ->load (__DIR__ . '/config/doctrine.php ' );
33
+ $ loader ->load (__DIR__ . '/config/doctrine_migrations.php ' );
34
34
$ loader ->load (__DIR__ . '/config/behat_doctrine_fixtures.yml ' );
35
35
}
36
36
@@ -43,4 +43,4 @@ public function getProjectDir(): string
43
43
{
44
44
return __DIR__ ;
45
45
}
46
- }
46
+ }
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ declare (strict_types=1 );
4
+
5
+ use Symfony \Component \DependencyInjection \Loader \Configurator \ContainerConfigurator ;
6
+
7
+ return static function (ContainerConfigurator $ containerConfigurator ): void {
8
+ $ containerConfigurator ->extension ('doctrine ' , [
9
+ 'dbal ' => [
10
+ 'url ' => 'sqlite:///%kernel.cache_dir%/data.db ' ,
11
+ 'options ' => [
12
+ 'collation ' => 'utf8mb4_unicode_ci ' ,
13
+ ],
14
+ ],
15
+ 'orm ' => [
16
+ 'auto_generate_proxy_classes ' => true ,
17
+ 'naming_strategy ' => 'doctrine.orm.naming_strategy.underscore_number_aware ' ,
18
+ 'auto_mapping ' => true ,
19
+ 'mappings ' => [
20
+ 'App ' => [
21
+ 'is_bundle ' => false ,
22
+ 'type ' => 'xml ' ,
23
+ 'dir ' => '%kernel.project_dir%/config/doctrine_entity ' ,
24
+ 'prefix ' => 'BehatDoctrineFixtures\Tests\Functional\App\Entity ' ,
25
+ 'alias ' => 'App ' ,
26
+ ],
27
+ ],
28
+ ],
29
+ ]);
30
+ };
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ <?xml version =" 1.0" encoding =" UTF-8" ?>
2
+ <doctrine-mapping xmlns =" http://doctrine-project.org/schemas/orm/doctrine-mapping"
3
+ xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance"
4
+ xsi : schemaLocation =" http://doctrine-project.org/schemas/orm/doctrine-mapping http://doctrine-project.org/schemas/orm/doctrine-mapping.xsd" >
5
+ <entity name =" BehatDoctrineFixtures\Tests\Functional\App\Entity\BaseEntity" table =" base_entity" >
6
+ <id name =" id" type =" integer" >
7
+ <generator strategy =" AUTO" />
8
+ <options >
9
+ <option name =" collation" >utf8_unicode_ci</option >
10
+ </options >
11
+ </id >
12
+ </entity >
13
+ </doctrine-mapping >
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ declare (strict_types=1 );
4
+
5
+ use Symfony \Component \DependencyInjection \Loader \Configurator \ContainerConfigurator ;
6
+
7
+ return static function (ContainerConfigurator $ containerConfigurator ): void {
8
+ $ containerConfigurator ->extension ('doctrine_migrations ' , [
9
+ 'storage ' => [
10
+ 'table_storage ' => [
11
+ 'table_name ' => 'migration_versions ' ,
12
+ ],
13
+ ],
14
+ 'migrations_paths ' => [
15
+ 'BehatDoctrineFixtures\Tests\Functional\App\Migrations ' => '%kernel.project_dir%/Migrations ' ,
16
+ ],
17
+ 'organize_migrations ' => 'BY_YEAR ' ,
18
+ 'custom_template ' => '%kernel.project_dir%/config/doctrine_migrations.template ' ,
19
+ ]);
20
+ };
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -17,15 +17,16 @@ protected function setUp(): void
17
17
{
18
18
parent ::setUp ();
19
19
20
- exec ('tests/Functional/App/bin/console doctrine:database:create --no-interaction ' );
21
- exec ('tests/Functional/App/bin/console d:mi:mi --no-interaction ' );
20
+ exec ('XDEBUG_MODE=off tests/Functional/App/bin/console doctrine:database:create --no-interaction ' );
21
+ exec ('XDEBUG_MODE=off tests/Functional/App/bin/console d:mi:mi --no-interaction ' );
22
+ exec ('rm -rf tests/Functional/App/var/cache/* ' );
22
23
}
23
24
24
25
protected function tearDown (): void
25
26
{
26
27
parent ::setUp ();
27
28
28
- exec ('tests/Functional/App/bin/console d:d:d --force --no-interaction ' );
29
+ exec ('XDEBUG_MODE=off tests/Functional/App/bin/console d:d:d --force --no-interaction ' );
29
30
}
30
31
31
32
public function testLoadFixtures (): void
You can’t perform that action at this time.
0 commit comments