Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tests/phpunit/tests/query/cacheResults.php
Original file line number Diff line number Diff line change
Expand Up @@ -1485,7 +1485,7 @@ public function test_main_comments_feed_includes_attachment_comments() {
$this->assertTrue( $query2->have_comments() );

$feed_comment = $query1->next_comment();
$this->assertEquals( $comment_id, $feed_comment->comment_ID );
$this->assertSame( (string) $comment_id, $feed_comment->comment_ID );
}

/**
Expand Down
12 changes: 6 additions & 6 deletions tests/phpunit/tests/query/results.php
Original file line number Diff line number Diff line change
Expand Up @@ -1071,7 +1071,7 @@ public function test_post_password() {
$result1 = $this->q->query( array_merge( $args, array( 'has_password' => true ) ) );
$this->assertEqualSets( array( $two, $three ), $result1 );
$result2 = $this->q->query( array_merge( $args, array( 'has_password' => false ) ) );
$this->assertEquals( array( $one ), $result2 );
$this->assertSame( array( (int) $one ), $result2 );

// This is equivalent to not passing it at all.
$result3 = $this->q->query( array_merge( $args, array( 'has_password' => null ) ) );
Expand All @@ -1087,7 +1087,7 @@ public function test_post_password() {
)
)
);
$this->assertEquals( array( $one ), $result4 );
$this->assertSame( array( (int) $one ), $result4 );
$result5 = $this->q->query(
array_merge(
$args,
Expand All @@ -1097,7 +1097,7 @@ public function test_post_password() {
)
)
);
$this->assertEquals( array( $one ), $result5 );
$this->assertSame( array( (int) $one ), $result5 );
$result6 = $this->q->query(
array_merge(
$args,
Expand All @@ -1107,7 +1107,7 @@ public function test_post_password() {
)
)
);
$this->assertEquals( array( $one ), $result6 );
$this->assertSame( array( (int) $one ), $result6 );

$result7 = $this->q->query(
array_merge(
Expand Down Expand Up @@ -1141,7 +1141,7 @@ public function test_post_password() {
$this->assertEqualSets( array( $two, $three ), $result9 );

$result10 = $this->q->query( array_merge( $args, array( 'post_password' => '' ) ) );
$this->assertEquals( array( $one ), $result10 );
$this->assertSame( array( (int) $one ), $result10 );
$result11 = $this->q->query( array_merge( $args, array( 'post_password' => 'burrito' ) ) );
$this->assertEqualSets( array( $two, $three ), $result11 );
}
Expand Down Expand Up @@ -1262,6 +1262,6 @@ public function test_main_comments_feed_includes_attachment_comments() {
$this->assertTrue( $this->q->have_comments() );

$feed_comment = $this->q->next_comment();
$this->assertEquals( $comment_id, $feed_comment->comment_ID );
$this->assertSame( (string) $comment_id, $feed_comment->comment_ID );
}
}
2 changes: 1 addition & 1 deletion tests/phpunit/tests/query/setupPostdata.php
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ public function test_setup_postdata_with_the_content() {
setup_postdata( $a_post );
$content = get_echo( 'the_content' );
$this->assertSame( $post_id, $GLOBALS['post']->ID );
$this->assertNotEquals( '<p>global post</p>', strip_ws( $content ) );
$this->assertNotSame( '<p>global post</p>', strip_ws( $content ) );
wp_reset_postdata();
}

Expand Down
Loading