REST API: Use delta comparison for floating date test added in [46279] to avoid race conditions.
See #48113. git-svn-id: https://develop.svn.wordpress.org/trunk@46318 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
f68fe85b41
commit
4f77abf6b9
@ -1428,6 +1428,6 @@ class Tests_Post extends WP_UnitTestCase {
|
||||
);
|
||||
|
||||
$post = get_post( $post_id );
|
||||
self::assertEquals( gmdate( 'Y-m-d H:i:s' ), $post->post_date_gmt );
|
||||
self::assertEquals( strtotime( gmdate( 'Y-m-d H:i:s' ) ), strtotime( $post->post_date_gmt ), 'The dates should be equal', 2 );
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user