Skip to content

Commit 942e786

Browse files
authored
Merge pull request #2321 from WordPress/feature/minimumwpversion-up-the-version
Update the `minimum_wp_version` to WP 6.0
2 parents bf9d82a + 230535a commit 942e786

File tree

5 files changed

+21
-21
lines changed

5 files changed

+21
-21
lines changed

WordPress/Helpers/MinimumWPVersionTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ trait MinimumWPVersionTrait {
8080
*
8181
* @var string WordPress version.
8282
*/
83-
private $default_minimum_wp_version = '5.8';
83+
private $default_minimum_wp_version = '6.0';
8484

8585
/**
8686
* Overrule the minimum supported WordPress version with a command-line/config value.

WordPress/Tests/WP/DeprecatedFunctionsUnitTest.inc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -354,16 +354,16 @@ wp_unregister_GLOBALS();
354354
noindex();
355355
wp_no_robots();
356356
wp_sensitive_page_meta();
357-
358-
/*
359-
* Warning.
360-
*/
361357
/* ============ WP 5.8 ============ */
362358
_excerpt_render_inner_columns_blocks();
363359
/* ============ WP 5.9 ============ */
364360
readonly();
365361
/* ============ WP 5.9.1 ============ */
366362
wp_render_duotone_filter_preset();
363+
364+
/*
365+
* Warning.
366+
*/
367367
/* ============ WP 6.0 ============ */
368368
image_attachment_fields_to_save();
369369
wp_add_iframed_editor_assets_html();

WordPress/Tests/WP/DeprecatedFunctionsUnitTest.php

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ final class DeprecatedFunctionsUnitTest extends AbstractSniffUnitTest {
3030
*/
3131
public function getErrorList() {
3232
$start_line = 8;
33-
$end_line = 356;
33+
$end_line = 362;
3434
$errors = array_fill( $start_line, ( ( $end_line - $start_line ) + 1 ), 1 );
3535

3636
// Unset the lines related to version comments.
@@ -72,9 +72,17 @@ public function getErrorList() {
7272
$errors[340],
7373
$errors[344],
7474
$errors[346],
75-
$errors[353]
75+
$errors[353],
76+
$errors[357],
77+
$errors[359],
78+
$errors[361]
7679
);
7780

81+
// Temporarily until PHPCS supports PHP 8.2.
82+
if ( \PHP_VERSION_ID >= 80200 ) {
83+
unset( $errors[360] ); // Function call to readonly.
84+
}
85+
7886
return $errors;
7987
}
8088

@@ -84,27 +92,19 @@ public function getErrorList() {
8492
* @return array <int line number> => <int number of warnings>
8593
*/
8694
public function getWarningList() {
87-
$start_line = 362;
95+
$start_line = 368;
8896
$end_line = 413;
8997
$warnings = array_fill( $start_line, ( ( $end_line - $start_line ) + 1 ), 1 );
9098

9199
// Unset the lines related to version comments.
92100
unset(
93-
$warnings[363],
94-
$warnings[365],
95-
$warnings[367],
96101
$warnings[373],
97102
$warnings[375],
98103
$warnings[377],
99104
$warnings[387],
100105
$warnings[390]
101106
);
102107

103-
// Temporarily until PHPCS supports PHP 8.2.
104-
if ( \PHP_VERSION_ID >= 80200 ) {
105-
unset( $warnings[364] ); // Function call to readonly.
106-
}
107-
108108
return $warnings;
109109
}
110110
}

WordPress/Tests/WP/DeprecatedParametersUnitTest.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ wp_install( is_public: '', user_name: '', user_email: '', deprecated: 'should be
4040
// All will give an ERROR. The functions are ordered alphabetically.
4141

4242
_future_post_hook( 10, $post );
43+
_load_remote_block_patterns( $value );
4344
_wp_post_revision_fields( $foo, 'deprecated' );
4445
add_option( '', '', [] );
4546
add_option( '', '', 1.23 );
@@ -95,5 +96,4 @@ wp_upload_bits( '', 'deprecated' );
9596
xfn_check( '', '', 'deprecated' );
9697

9798
// All will give an WARNING as they have been deprecated after WP 5.8.
98-
_load_remote_block_patterns( $value );
9999
global_terms( $foo, 'deprecated' );

WordPress/Tests/WP/DeprecatedParametersUnitTest.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ final class DeprecatedParametersUnitTest extends AbstractSniffUnitTest {
3030
*/
3131
public function getErrorList() {
3232
$start_line = 42;
33-
$end_line = 95;
33+
$end_line = 96;
3434
$errors = array_fill( $start_line, ( ( $end_line - $start_line ) + 1 ), 1 );
3535

3636
$errors[22] = 1;
@@ -41,8 +41,8 @@ public function getErrorList() {
4141
$errors[38] = 1;
4242

4343
// Override number of errors.
44-
$errors[49] = 2;
45-
$errors[75] = 2;
44+
$errors[50] = 2;
45+
$errors[76] = 2;
4646

4747
return $errors;
4848
}
@@ -53,7 +53,7 @@ public function getErrorList() {
5353
* @return array <int line number> => <int number of warnings>
5454
*/
5555
public function getWarningList() {
56-
$start_line = 98;
56+
$start_line = 99;
5757
$end_line = 99;
5858
$errors = array_fill( $start_line, ( ( $end_line - $start_line ) + 1 ), 1 );
5959

0 commit comments

Comments
 (0)