Skip to content

Commit

Permalink
wrap test in function
Browse files Browse the repository at this point in the history
  • Loading branch information
verfriemelt-dot-org committed Dec 12, 2022
1 parent 96c71a9 commit eddc6a2
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/PHPStan/Analyser/data/bug-8442.php
Expand Up @@ -5,5 +5,8 @@
use function PHPStan\Testing\assertType;
use DateInterval;

assertType('false', DateInterval::createFromDateString('foo'));
assertType('DateInterval', DateInterval::createFromDateString('1 Day'));
function () {
assertType('false', DateInterval::createFromDateString('foo'));
assertType('DateInterval', DateInterval::createFromDateString('1 Day'));
};

0 comments on commit eddc6a2

Please sign in to comment.