Skip to content

Commit

Permalink
phpstan tests fix (removed polyfill-php80 and added interface stub)
Browse files Browse the repository at this point in the history
  • Loading branch information
Roman Riska committed Oct 12, 2023
1 parent e4f2fbd commit 65ce88f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 2 deletions.
3 changes: 1 addition & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
],
"require": {
"php": "^7.2 || ^8.0",
"phpstan/phpstan": "^1.10",
"symfony/polyfill-php80": "^1.28"
"phpstan/phpstan": "^1.10"
},
"conflict": {
"nette/application": "<2.3.0",
Expand Down
1 change: 1 addition & 0 deletions extension.neon
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ parameters:
- stubs/Utils/Html.stub
- stubs/Utils/Paginator.stub
- stubs/Utils/Random.stub
- stubs/Stringable.stub
universalObjectCratesClasses:
- Nette\Application\UI\ITemplate
- Nette\Application\UI\Template
Expand Down
13 changes: 13 additions & 0 deletions stubs/Stringable.stub
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

if (\PHP_VERSION_ID < 80000) {
interface Stringable
{
/**
* @return string
*/
public function __toString();
}
}

0 comments on commit 65ce88f

Please sign in to comment.