Skip to content

Commit 667b7f4

Browse files
authored
Merge pull request #13 from chirimoya/symfony-4-support
Symfony 4 support
2 parents 5b59531 + cc79d4e commit 667b7f4

File tree

7 files changed

+45
-23
lines changed

7 files changed

+45
-23
lines changed

.travis.yml

Lines changed: 28 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,35 @@
1-
language: php
2-
3-
php:
4-
- 5.6
5-
- 7.0
1+
sudo: false
62

73
env:
8-
- SYMFONY_VERSION=2.8.*
9-
- SYMFONY_VERSION=3.0.*
10-
- SYMFONY_VERSION=dev-master
4+
global:
5+
- KERNEL_CLASS=DTL\\Bundle\\PhpcrMigrations\\Tests\\Resources\\App\\AppKernel
6+
7+
matrix:
8+
include:
9+
- language: php
10+
php: 7.1
11+
env:
12+
- SYMFONY_VERSION=2.8.*
13+
14+
- language: php
15+
php: 7.1
16+
env:
17+
- SYMFONY_VERSION=3.4.*
18+
19+
- language: php
20+
php: 7.2
21+
env:
22+
- SYMFONY_VERSION=4.0.*
23+
24+
- language: php
25+
php: 7.2
26+
env:
27+
- SYMFONY_VERSION=4.1.*
1128

1229
before_script:
30+
- phpenv config-add travis.php.ini
31+
- composer self-update
1332
- composer require symfony/symfony:${SYMFONY_VERSION}
1433
- vendor/symfony-cmf/testing/bin/travis/phpcr_odm_doctrine_dbal.sh
1534

16-
script: phpunit
17-
18-
matrix:
19-
allow_failures:
20-
- env: SYMFONY_VERSION=dev-master
35+
script: vendor/bin/phpunit

Resources/config/services.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@
44
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">
55

66
<services>
7-
<service id="phpcr_migrations.version_storage" class="PHPCR\Migrations\VersionStorage" public="false">
7+
<service id="phpcr_migrations.version_storage" class="PHPCR\Migrations\VersionStorage">
88
<argument type="service" id="doctrine_phpcr.default_session" />
99
<argument>%phpcr_migrations.version_node_name%</argument>
1010
</service>
1111

12-
<service id="phpcr_migrations.version_finder" class="PHPCR\Migrations\VersionFinder" public="false">
12+
<service id="phpcr_migrations.version_finder" class="PHPCR\Migrations\VersionFinder">
1313
<argument>%phpcr_migrations.paths%</argument>
1414
</service>
1515

@@ -19,19 +19,19 @@
1919
<argument type="service" id="doctrine_phpcr.session" />
2020
</service>
2121

22-
<service id="phpcr_migrations.command.status" class="DTL\Bundle\PhpcrMigrations\Command\StatusCommand">
22+
<service id="phpcr_migrations.command.status" class="DTL\Bundle\PhpcrMigrations\Command\StatusCommand" public="true">
2323
<argument type="service" id="phpcr_migrations.version_storage" />
2424
<argument type="service" id="phpcr_migrations.version_finder" />
2525
<tag name="console.command" />
2626
</service>
2727

28-
<service id="phpcr_migrations.command.migrate" class="DTL\Bundle\PhpcrMigrations\Command\MigrateCommand">
28+
<service id="phpcr_migrations.command.migrate" class="DTL\Bundle\PhpcrMigrations\Command\MigrateCommand" public="true">
2929
<argument type="service" id="phpcr_migrations.migrator_factory" />
3030
<argument type="service" id="service_container" />
3131
<tag name="console.command" />
3232
</service>
3333

34-
<service id="phpcr_migrations.command.initialize" class="DTL\Bundle\PhpcrMigrations\Command\InitializeCommand">
34+
<service id="phpcr_migrations.command.initialize" class="DTL\Bundle\PhpcrMigrations\Command\InitializeCommand" public="true">
3535
<argument type="service" id="phpcr_migrations.migrator_factory" />
3636
<tag name="console.command" />
3737
</service>

Tests/Resources/app/AppKernel.php renamed to Tests/Resources/App/AppKernel.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
* file that was distributed with this source code.
1010
*/
1111

12+
namespace DTL\Bundle\PhpcrMigrations\Tests\Resources\App;
13+
1214
use DTL\Bundle\PhpcrMigrations\PhpcrMigrationsBundle;
1315
use DTL\Bundle\PhpcrMigrations\Tests\Resources\Bundle\OneTestBundle\OneTestBundle;
1416
use DTL\Bundle\PhpcrMigrations\Tests\Resources\Bundle\TwoTestBundle\TwoTestBundle;
File renamed without changes.

composer.json

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,17 @@
99
}
1010
],
1111
"require": {
12-
"phpcr/phpcr-migrations": "^1.0",
12+
"phpcr/phpcr-migrations": "^1.1",
1313
"phpcr/phpcr-implementation": "^2.1",
14-
"doctrine/phpcr-bundle": "^1.2"
14+
"doctrine/phpcr-bundle": "^1.3 || ^2.0"
1515
},
1616
"require-dev": {
17-
"symfony/symfony": "~2.8 || ~3.0",
18-
"symfony-cmf/testing": "~1.3"
17+
"symfony/symfony": "~2.8 || ~3.4 || ~4.0",
18+
"symfony-cmf/testing": "~2.1",
19+
"phpunit/phpunit": "~5.7"
20+
},
21+
"conflict": {
22+
"symfony/symfony": "3.4.15"
1923
},
2024
"autoload": {
2125
"psr-4": {

phpunit.xml.dist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
</filter>
2323

2424
<php>
25-
<server name="KERNEL_DIR" value="Tests/Resources/app" />
25+
<server name="KERNEL_CLASS" value="DTL\Bundle\PhpcrMigrations\Tests\Resources\App\AppKernel" />
2626
</php>
2727

2828
</phpunit>

travis.php.ini

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
memory_limit = 2048M

0 commit comments

Comments
 (0)