Skip to content

Commit

Permalink
Merge pull request #349 from Yoast/JRF/CS-various-minor-tweaks
Browse files Browse the repository at this point in the history
CS: minor tweaks to comply with YoastCS 3.0
  • Loading branch information
jrfnl authored Dec 16, 2023
2 parents 6c54b9b + 4e35cef commit 30fbd3d
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 8 deletions.
1 change: 0 additions & 1 deletion src/ui/newsletter.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ public static function newsletter_signup_form() {

$newsletter_form_response = self::newsletter_handle_form();


$copy = \sprintf(
/* translators: 1: Yoast */
\esc_html__(
Expand Down
8 changes: 4 additions & 4 deletions tests/Unit/Admin/Options_Form_Generator_Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ public function test_generate_options_input_for_suboptions() {
Monkey\Functions\expect( 'checked' )
->once()
->andReturnUsing(
static function( $checked, $current = true ) {
static function ( $checked, $current = true ) {
return ( (string) $checked === (string) $current ) ? " checked='checked'" : '';
}
);
Expand Down Expand Up @@ -345,7 +345,7 @@ public function test_generate_taxonomy_exclusion_list() {
Monkey\Functions\expect( 'checked' )
->times( 4 )
->andReturnUsing(
static function( $checked, $current = true ) {
static function ( $checked, $current = true ) {
return ( (string) $checked === (string) $current ) ? " checked='checked'" : '';
}
);
Expand Down Expand Up @@ -381,7 +381,7 @@ public function test_generate_roles_permission_list() {
Monkey\Functions\expect( 'checked' )
->twice()
->andReturnUsing(
static function( $checked, $current = true ) {
static function ( $checked, $current = true ) {
return ( (string) $checked === (string) $current ) ? " checked='checked'" : '';
}
);
Expand Down Expand Up @@ -421,7 +421,7 @@ public function test_generate_post_types_list() {
Monkey\Functions\expect( 'checked' )
->twice()
->andReturnUsing(
static function( $checked, $current = true ) {
static function ( $checked, $current = true ) {
return ( (string) $checked === (string) $current ) ? " checked='checked'" : '';
}
);
Expand Down
2 changes: 1 addition & 1 deletion tests/Unit/Admin/Options_Inputs_Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function test_checkbox() {
Functions\expect( 'checked' )
->twice()
->andReturnUsing(
static function( $checked, $current = true ) {
static function ( $checked, $current = true ) {
return ( (string) $checked === (string) $current ) ? " checked='checked'" : '';
}
);
Expand Down
2 changes: 1 addition & 1 deletion tests/WP/Post_Duplicator_Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

namespace Yoast\WP\Duplicate_Post\Tests\WP;

use Yoast\WPTestUtils\WPIntegration\TestCase;
use Yoast\WP\Duplicate_Post\Post_Duplicator;
use Yoast\WPTestUtils\WPIntegration\TestCase;

/**
* Class Post_Duplicator.
Expand Down
2 changes: 1 addition & 1 deletion tests/WP/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

\tests_add_filter(
'muplugins_loaded',
function() {
static function () {
require_once \dirname( __DIR__, 2 ) . '/duplicate-post.php';
}
);
Expand Down

0 comments on commit 30fbd3d

Please sign in to comment.