Skip to content

Commit

Permalink
Merge pull request #92 from pechondra/3813-php-80
Browse files Browse the repository at this point in the history
Support for PHP 8.0
  • Loading branch information
Spamercz committed Aug 6, 2021
2 parents fe61378 + 18a874b commit cee7512
Show file tree
Hide file tree
Showing 5 changed files with 56 additions and 78 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/php-package-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Package CI

on:
pull_request:

jobs:
checks:
name: Checks
runs-on: ubuntu-latest
strategy:
matrix:
php: [ 7.4, 8.0 ]
steps:
- uses: actions/checkout@v2
- uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}

- run: make composer

- run: make phpstan

- run: make tester
63 changes: 0 additions & 63 deletions .travis.yml

This file was deleted.

13 changes: 13 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
composer:
composer validate
composer update --no-interaction --prefer-dist

cs:
vendor/bin/phpcs --standard=./ruleset.xml --cache=${HOME}/phpcs-cache/.phpcs-cache --encoding=utf-8 -sp src tests/KdybyTests
vendor/bin/parallel-lint -e php,phpt --exclude vendor .

phpstan:
vendor/bin/phpstan analyse src tests/KdybyTests

tester:
vendor/bin/tester -s -c ./tests/php.ini-unix ./tests/KdybyTests/
33 changes: 19 additions & 14 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,26 +17,26 @@
"issues": "https://github.com/kdyby/console/issues"
},
"require": {
"php": ">=7.1",
"nette/di": "^2.4.10 || ^3.0",
"php": "^7.4 | ^8.0",
"nette/di": "^3.0",
"nette/routing": "^3.0.0",
"tracy/tracy": "^2.5 || ^3.0",
"nette/utils": "~3.1.0",
"symfony/console": "~2.3 || ^3.0 || < 4.3"
"tracy/tracy": "^2.8 || ^3.0",
"nette/utils": "^3.0",
"symfony/console": "~2.3 || ^3.0 || ^4.0"
},
"require-dev": {
"nette/application": "3.0.*",
"nette/bootstrap": "^2.4.5 || ^3.0",
"nette/caching": "^2.5 || ^3.0",
"nette/application": "^3.0",
"nette/bootstrap": "^3.0",
"nette/caching": "^3.0",
"nette/http": "^3.0",
"kdyby/events": "^3.2@dev",
"symfony/event-dispatcher": "~2.3 || ^3.0 || ^4.0 < 4.3",
"kdyby/events": "dev-patch-1 as 3.2.99",
"symfony/event-dispatcher": "~2.3 || ^3.0 || ^4.0",

"nette/tester": "^2.2",
"phpstan/phpstan-shim": "^0.11.5",
"kdyby/coding-standard": "dev-master",
"phpstan/phpstan": "^0.12.88",
"doctrine/coding-standard": "8.2.*",
"php-coveralls/php-coveralls": "^2.1",
"jakub-onderka/php-parallel-lint": "^1.0",
"php-parallel-lint/php-parallel-lint": "^v1.2.0",
"typo3/class-alias-loader": "^1.0"
},
"suggest": {
Expand All @@ -58,7 +58,12 @@
"tests/KdybyTests/"
]
},
"minimum-stability": "dev",
"repositories": [
{
"type": "vcs",
"url": "https://github.com/dakorpar/Events.git"
}
],
"extra": {
"branch-alias": {
"dev-master": "2.8-dev"
Expand Down
2 changes: 1 addition & 1 deletion tests/KdybyTests/Console/CliRouterTest.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class CliRouterTest extends \Tester\TestCase
/** @var \Nette\Application\Routers\RouteList $router */
Assert::true($router instanceof RouteList);

[$cliRouter] = iterator_to_array($router->getIterator());
[$cliRouter] = $router->getRouters();
/** @var \Kdyby\Console\CliRouter $cliRouter */
Assert::true($cliRouter instanceof CliRouter);

Expand Down

0 comments on commit cee7512

Please sign in to comment.