Skip to content

Commit c9d4ebb

Browse files
committed
adding phpcbf fixes
1 parent 4950207 commit c9d4ebb

File tree

1 file changed

+18
-6
lines changed

1 file changed

+18
-6
lines changed

tests/phpunit/tests/user.php

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -900,12 +900,19 @@ private function create_user_with_blogs( $num_blogs = 1, $include_main_site = fa
900900
}
901901

902902
for ( $i = 0; $i < $num_blogs; $i++ ) {
903-
$blog_id = self::factory()->blog->create( array( 'site_id' => get_current_network_id() ) );
903+
$blog_id = self::factory()->blog->create(
904+
array(
905+
'site_id' => get_current_network_id(),
906+
)
907+
);
904908
add_user_to_blog( $blog_id, $user_id, 'administrator' );
905909
$blogs[] = $blog_id;
906910
}
907911

908-
return array( 'user_id' => $user_id, 'blogs' => $blogs );
912+
return array(
913+
'user_id' => $user_id,
914+
'blogs' => $blogs,
915+
);
909916
}
910917

911918
/**
@@ -916,18 +923,23 @@ public function test_default_do_not_propagate_network_user_spam_to_blogs_on_mult
916923
$this->markTestSkipped( 'This test is for multisite only.' );
917924
}
918925

919-
$data = $this->create_user_with_blogs( 2 );
926+
$data = $this->create_user_with_blogs( 2 );
920927
$user_id = $data['user_id'];
921-
$blogs = $data['blogs'];
928+
$blogs = $data['blogs'];
922929

923930
// Mark user spam in user record (this alone should not change blog spam states).
924-
$u = wp_update_user( array( 'ID' => $user_id, 'spam' => '1' ) );
931+
$u = wp_update_user(
932+
array(
933+
'ID' => $user_id,
934+
'spam' => '1',
935+
)
936+
);
925937
$this->assertNotWPError( $u );
926938
$user = get_userdata( $user_id );
927939
$this->assertSame( '1', $user->spam );
928940

929941
foreach ( $blogs as $blog_id ) {
930-
$this->assertNotEquals( '1', get_blog_status( $blog_id, 'spam' ), "Blog {$blog_id} should not be marked spam by default." );
942+
$this->assertNotSame( '1', get_blog_status( $blog_id, 'spam' ), "Blog {$blog_id} should not be marked spam by default." );
931943
}
932944
}
933945

0 commit comments

Comments
 (0)