Skip to content

Commit

Permalink
Merge 91d552e into c7370b6
Browse files Browse the repository at this point in the history
  • Loading branch information
jordisala1991 committed Jul 29, 2020
2 parents c7370b6 + 91d552e commit 7e7002f
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 19 deletions.
5 changes: 5 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,16 @@ matrix:
env: SYMFONY=4.4.*
- php: '7.3'
env: SYMFONY='dev-master as 4.4.x-dev'
- php: '7.3'
env: SONATA_USER=4.*
- php: '7.3'
env: SONATA_USER='dev-master as 4.x-dev'
- php: '7.3'
env: SYMFONY_DEPRECATIONS_HELPER=0
allow_failures:
- php: nightly
- env: SYMFONY_DEPRECATIONS_HELPER=0
- env: SONATA_USER='dev-master as 4.x-dev'
- env: SYMFONY='dev-master as 4.4.x-dev'

before_install:
Expand Down
1 change: 1 addition & 0 deletions .travis/before_install_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ echo "memory_limit=3072M" >> "$TRAVIS_INI_FILE"
sed --in-place "s/\"dev-master\":/\"dev-${TRAVIS_COMMIT}\":/" composer.json

if [ "$SYMFONY" != "" ]; then composer require "symfony/symfony:$SYMFONY" --no-update; fi;
if [ "$SONATA_USER" != "" ]; then composer require "sonata-project/user-bundle:$SONATA_USER" --no-update; fi;
17 changes: 8 additions & 9 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,23 +22,22 @@
}
],
"require": {
"php": "^7.1",
"symfony/config": "^4.4",
"symfony/dependency-injection": "^4.4",
"symfony/http-foundation": "^4.4",
"symfony/http-kernel": "^4.4",
"php": "^7.2",
"symfony/config": "^4.4 || ^5.0",
"symfony/dependency-injection": "^4.4 || ^5.0",
"symfony/http-foundation": "^4.4 || ^5.0",
"symfony/http-kernel": "^4.4 || ^5.0",
"symfony/intl": "^4.4 || ^5.0",
"symfony/templating": "^4.4",
"twig/twig": "^2.9"
"twig/twig": "^2.9 || ^3.0"
},
"conflict": {
"sonata-project/user-bundle": "<2.0 || >=5.0"
"sonata-project/user-bundle": "<3.6"
},
"require-dev": {
"matthiasnoback/symfony-dependency-injection-test": "^4.0",
"sonata-project/user-bundle": "^3.6 || ^4.0",
"symfony/phpunit-bridge": "^5.1",
"symfony/security-core": "^4.4"
"symfony/security-core": "^4.4 || ^5.0"
},
"config": {
"sort-packages": true
Expand Down
6 changes: 6 additions & 0 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
parameters:
ignoreErrors:
-
message: "#^Class Sonata\\\\UserBundle\\\\Model\\\\User not found\\.$#"
count: 2
path: src/Timezone/UserBasedTimezoneDetector.php
6 changes: 3 additions & 3 deletions phpstan.neon.dist
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
includes:
- phpstan-baseline.neon

parameters:
level: 1

Expand All @@ -9,6 +12,3 @@ parameters:
excludes_analyse:
- src/Test/AbstractWidgetTestCase.php
- tests/bootstrap.php

autoload_files:
- vendor/autoload.php
8 changes: 1 addition & 7 deletions src/DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,7 @@ class Configuration implements ConfigurationInterface
public function getConfigTreeBuilder()
{
$treeBuilder = new TreeBuilder('sonata_intl');

// Keep compatibility with symfony/config < 4.2
if (!method_exists($treeBuilder, 'getRootNode')) {
$rootNode = $treeBuilder->root('sonata_intl');
} else {
$rootNode = $treeBuilder->getRootNode();
}
$rootNode = $treeBuilder->getRootNode();

$rootNode
->children()
Expand Down

0 comments on commit 7e7002f

Please sign in to comment.