Skip to content

Commit 428a7bf

Browse files
authored
minor #29 Use modern php versions (vkhramtsov)
This PR was merged into the 1.0-dev branch. Discussion ---------- | Q | A | ------------- | --- | Bug fix? | no | New feature? | no | BC breaks? | yes | Deprecations? | no | Tests pass? | yes | Fixed tickets | #28 | License | MIT Commits ------- a0a28e0 Use modern php versions e4a9bf8 Update phpunit version a0979b4 Remove symfony 2 requirement. Update php-cs-fixer 051f440 Do not add \ to native functions c6083e5 Fix php-cs-fixer rules. Use higher versions of dependencies cef6ec5 Add build with non modified deps 674bf19 Change build matrix
2 parents e94ae9c + 674bf19 commit 428a7bf

File tree

3 files changed

+22
-16
lines changed

3 files changed

+22
-16
lines changed

.php_cs

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ with this source code in the file LICENSE.
1010
EOF;
1111

1212
return PhpCsFixer\Config::create()
13-
->setRules(array(
13+
->setRules([
1414
'@Symfony' => true,
1515
'@Symfony:risky' => true,
1616
'array_syntax' => ['syntax' => 'short'],
@@ -19,8 +19,13 @@ return PhpCsFixer\Config::create()
1919
'header_comment' => ['header' => $header],
2020
'heredoc_to_nowdoc' => false,
2121
'phpdoc_annotation_without_dot' => false,
22-
'yoda_style' => false
23-
))
22+
'yoda_style' => false,
23+
'native_function_invocation' => false,
24+
'phpdoc_types_order' => [
25+
'null_adjustment' => 'none',
26+
'sort_algorithm' => 'none',
27+
],
28+
])
2429
->setRiskyAllowed(true)
2530
->setFinder(
2631
PhpCsFixer\Finder::create()

.travis.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@ language: php
22

33
matrix:
44
include:
5-
- php: 5.6
6-
- php: 7.0
7-
env: lint=1
8-
- php: 7.1
9-
env: DEPENDENCIES='dev' lint=1
105
- php: 7.1
6+
- php: 7.2
7+
env: DEPENDENCIES='dev'
8+
- php: 7.2
119
env: DEPENDENCIES='low'
10+
- php: 7.2
11+
- php: 7.3
12+
env: lint=1
1213
fast_finish: true
1314

1415
sudo: false
@@ -20,7 +21,7 @@ cache:
2021
before_install:
2122
- phpenv config-rm xdebug.ini || echo "xdebug not available"
2223
- echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini
23-
- if [[ $lint = 1 ]]; then wget https://github.com/FriendsOfPHP/PHP-CS-Fixer/releases/download/v2.6.0/php-cs-fixer.phar; fi
24+
- if [[ $lint = 1 ]]; then wget https://github.com/FriendsOfPHP/PHP-CS-Fixer/releases/download/v2.14.2/php-cs-fixer.phar; fi
2425
- if [[ $lint = 1 ]]; then composer global require --dev 'phpstan/phpstan:^0.8'; fi
2526
- export PATH="$PATH:$HOME/.composer/vendor/bin"
2627

@@ -30,7 +31,7 @@ install:
3031
- if [ "$DEPENDENCIES" == "low" ]; then composer update --prefer-dist --no-progress --no-suggest --ansi --prefer-lowest; fi;
3132

3233
script:
33-
- export SYMFONY_PHPUNIT_VERSION=5.7.1
34+
- export SYMFONY_PHPUNIT_VERSION=7.5.6
3435
- export SYMFONY_PHPUNIT_REMOVE="symfony/yaml"
3536
- export SYMFONY_DEPRECATIONS_HELPER=strict
3637
- vendor/bin/simple-phpunit --verbose

composer.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,17 @@
1919
}
2020
],
2121
"require": {
22-
"php": "^5.6 || ^7.0",
22+
"php": "^7.1",
2323
"psr/container": "^1.0",
2424
"psr/log": "^1.0",
2525
"symfony/polyfill-mbstring": "^1.5.0",
26-
"symfony/translation": "^2.8.9 || ^3.3.6 | ^4.0",
27-
"symfony/validator": "^2.8.9 || ^3.3.6 || ^4.0"
26+
"symfony/translation": "^3.4.22 || ^4.0",
27+
"symfony/validator": "^3.4.22 || ^4.0"
2828
},
2929
"require-dev": {
30-
"symfony/config": "^3.3.6 || ^4.0",
31-
"symfony/console": "^3.3.6 || ^4.0",
32-
"symfony/phpunit-bridge": "^3.3.6 || ^4.0",
30+
"symfony/config": "^3.4.22 || ^4.0",
31+
"symfony/console": "^3.4.22 || ^4.0",
32+
"symfony/phpunit-bridge": "^3.4.22 || ^4.0",
3333
"php-http/httplug": "^1.1",
3434
"guzzlehttp/psr7": "^1.4"
3535
},

0 commit comments

Comments
 (0)