-
Notifications
You must be signed in to change notification settings - Fork 574
Expand file tree
/
Copy pathignore-by-php-version.neon.php
More file actions
57 lines (46 loc) · 1.36 KB
/
ignore-by-php-version.neon.php
File metadata and controls
57 lines (46 loc) · 1.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
<?php declare(strict_types = 1);
$includes = [];
if (PHP_VERSION_ID >= 80000) {
$includes[] = __DIR__ . '/baseline-8.0.neon';
} else {
$includes[] = __DIR__ . '/baseline-pre-8.0.neon';
}
if (PHP_VERSION_ID >= 80100) {
$includes[] = __DIR__ . '/baseline-8.1.neon';
$includes[] = __DIR__ . '/../vendor/shipmonk/dead-code-detector/rules.neon';
} else {
$includes[] = __DIR__ . '/enums.neon';
$includes[] = __DIR__ . '/readonly-property.neon';
}
if (PHP_VERSION_ID >= 70400) {
$includes[] = __DIR__ . '/ignore-gte-php7.4-errors.neon';
}
if (PHP_VERSION_ID < 80000) {
$includes[] = __DIR__ . '/more-enum-adapter-errors.neon';
}
if (PHP_VERSION_ID < 80000) {
$includes[] = __DIR__ . '/spl-autoload-functions-pre-php-7.neon';
} else {
$includes[] = __DIR__ . '/spl-autoload-functions-php-8.neon';
}
if (PHP_VERSION_ID >= 80400) {
$includes[] = __DIR__ . '/deprecated-8.4.neon';
}
if (PHP_VERSION_ID < 80200) {
$includes[] = __DIR__ . '/old-phpunit.neon';
} else {
$includes[] = __DIR__ . '/new-phpunit.neon';
}
if (PHP_VERSION_ID < 80500) {
$includes[] = __DIR__ . '/pre-php-85.neon';
} else {
$includes[] = __DIR__ . '/php-85.neon';
}
if (PHP_VERSION_ID < 80100) {
$includes[] = __DIR__ . '/fiber.neon';
}
$config = [];
$config['includes'] = $includes;
// overrides config.platform.php in composer.json
$config['parameters']['phpVersion'] = PHP_VERSION_ID;
return $config;