Skip to content

Commit 6e3a9f6

Browse files
committed
tests: regenerate PHPStan baselines after rebase
1 parent df6b36e commit 6e3a9f6

3 files changed

Lines changed: 6 additions & 30 deletions

File tree

tests/phpstan/baseline/level-1.php

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -385,11 +385,5 @@
385385
'count' => 1,
386386
'path' => __DIR__ . '/../../../src/wp-includes/widgets.php',
387387
];
388-
$ignoreErrors[] = [
389-
// identifier: isset.variable
390-
'message' => '#^Variable \\$HTTP_RAW_POST_DATA in isset\\(\\) always exists and is not nullable\\.$#',
391-
'count' => 1,
392-
'path' => __DIR__ . '/../../../src/xmlrpc.php',
393-
];
394388

395389
return ['parameters' => ['ignoreErrors' => $ignoreErrors]];

tests/phpstan/baseline/level-2.php

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1015,12 +1015,6 @@
10151015
'count' => 1,
10161016
'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block.php',
10171017
];
1018-
$ignoreErrors[] = [
1019-
// identifier: arguments.count
1020-
'message' => '#^Method WP_HTML_Tag_Processor\\:\\:get_tag\\(\\) invoked with 1 parameter, 0 required\\.$#',
1021-
'count' => 1,
1022-
'path' => __DIR__ . '/../../../src/wp-includes/class-wp-block.php',
1023-
];
10241018
$ignoreErrors[] = [
10251019
// identifier: staticClassAccess.privateMethod
10261020
'message' => '#^Unsafe call to private method WP_Classic_To_Block_Menu_Converter\\:\\:group_by_parent_id\\(\\) through static\\:\\:\\.$#',
@@ -1657,12 +1651,6 @@
16571651
'count' => 3,
16581652
'path' => __DIR__ . '/../../../src/wp-includes/nav-menu.php',
16591653
];
1660-
$ignoreErrors[] = [
1661-
// identifier: greater.invalid
1662-
'message' => '#^Comparison operation "\\>" between 0\\|array\\<int, string\\>\\|string\\|null and int results in an error\\.$#',
1663-
'count' => 1,
1664-
'path' => __DIR__ . '/../../../src/wp-includes/option.php',
1665-
];
16661654
$ignoreErrors[] = [
16671655
// identifier: parameter.defaultValue
16681656
'message' => '#^Default value of the parameter \\#3 \\$deprecated \\(\'\'\\) of function unregister_setting\\(\\) is incompatible with type callable\\(\\)\\: mixed\\.$#',
@@ -1795,12 +1783,6 @@
17951783
'count' => 1,
17961784
'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php',
17971785
];
1798-
$ignoreErrors[] = [
1799-
// identifier: property.private
1800-
'message' => '#^Access to private property WP_User_Query\\:\\:\\$results\\.$#',
1801-
'count' => 1,
1802-
'path' => __DIR__ . '/../../../src/wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php',
1803-
];
18041786
$ignoreErrors[] = [
18051787
// identifier: property.nonObject
18061788
'message' => '#^Cannot access property \\$post_content on array\\|object\\.$#',
@@ -1885,12 +1867,6 @@
18851867
'count' => 1,
18861868
'path' => __DIR__ . '/../../../src/wp-includes/user.php',
18871869
];
1888-
$ignoreErrors[] = [
1889-
// identifier: binaryOp.invalid
1890-
'message' => '#^Binary operation "\\-" between string and int\\<1, max\\> results in an error\\.$#',
1891-
'count' => 1,
1892-
'path' => __DIR__ . '/../../../src/wp-includes/user.php',
1893-
];
18941870
$ignoreErrors[] = [
18951871
// identifier: return.missing
18961872
'message' => '#^Function wp_list_users\\(\\) should return string\\|null but return statement is missing\\.$#',

tests/phpstan/baseline/level-4.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -529,6 +529,12 @@
529529
'count' => 1,
530530
'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php',
531531
];
532+
$ignoreErrors[] = [
533+
// identifier: elseif.alwaysTrue
534+
'message' => '#^Elseif condition is always true\\.$#',
535+
'count' => 1,
536+
'path' => __DIR__ . '/../../../src/wp-admin/includes/image.php',
537+
];
532538
$ignoreErrors[] = [
533539
// identifier: booleanAnd.alwaysFalse
534540
'message' => '#^Result of && is always false\\.$#',

0 commit comments

Comments
 (0)