Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
| FuturePhpVersion | n/a |
0 / 0 |
n/a |
0 / 0 |
4 | n/a |
0 / 0 |
|||
| __construct | n/a |
0 / 0 |
n/a |
0 / 0 |
1 | |||||
| loadPhp84Classes | n/a |
0 / 0 |
n/a |
0 / 0 |
3 | |||||
| 1 | <?php |
| 2 | |
| 3 | namespace Apie\Fixtures; |
| 4 | |
| 5 | use Symfony\Component\Finder\Finder; |
| 6 | |
| 7 | /** |
| 8 | * @codeCoverageIgnore |
| 9 | */ |
| 10 | final class FuturePhpVersion |
| 11 | { |
| 12 | private function __construct() |
| 13 | { |
| 14 | } |
| 15 | |
| 16 | public static function loadPhp84Classes(): void |
| 17 | { |
| 18 | if (PHP_VERSION_ID < 80400) { |
| 19 | throw new \LogicException('This is not PHP version 8.4 or newer, this is PHP version ' . PHP_VERSION); |
| 20 | } |
| 21 | foreach (Finder::create()->in(__DIR__ . '/../php84')->files()->name('*.php') as $phpFile) { |
| 22 | require_once $phpFile->getRealPath(); |
| 23 | } |
| 24 | } |
| 25 | } |