Coding Standards: Fix WPCS violations in [45851].
See #25347. git-svn-id: https://develop.svn.wordpress.org/trunk@45852 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
896da178e0
commit
f2b6c12ddb
@ -309,17 +309,21 @@ class Tests_WPInsertPost extends WP_UnitTestCase {
|
||||
|
||||
$now = new DateTimeImmutable( 'now', new DateTimeZone( 'UTC' ) );
|
||||
|
||||
$post_id = $this->factory()->post->create( [
|
||||
$post_id = $this->factory()->post->create(
|
||||
array(
|
||||
'post_date_gmt' => $now->modify( '-1 year' )->format( 'Y-m-d H:i:s' ),
|
||||
'post_status' => 'future',
|
||||
] );
|
||||
)
|
||||
);
|
||||
|
||||
$this->assertEquals( 'publish', get_post_status( $post_id ) );
|
||||
|
||||
$post_id = $this->factory()->post->create( [
|
||||
$post_id = $this->factory()->post->create(
|
||||
array(
|
||||
'post_date_gmt' => $now->modify( '+50 years' )->format( 'Y-m-d H:i:s' ),
|
||||
'post_status' => 'future',
|
||||
] );
|
||||
)
|
||||
);
|
||||
|
||||
$this->assertEquals( 'future', get_post_status( $post_id ) );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user