mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 21:00:21 +00:00
Tests: Use more appropriate assertions in various tests.
This replaces instances of `assertTrue( is_numeric( ... ) )` with `assertIsNumeric()` to use native PHPUnit functionality. Follow-up to [51335], [51337], [51367], [51397], [51403], [51404], [51436]. See #53363. git-svn-id: https://develop.svn.wordpress.org/trunk@51438 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1214,7 +1214,7 @@ class Tests_WP_Customize_Manager extends WP_UnitTestCase {
|
||||
$this->assertSame( $manager->changeset_uuid(), get_post( $post_id )->post_name, 'Expected that the "__trashed" suffix to not be added.' );
|
||||
wp_set_current_user( self::$admin_user_id );
|
||||
$this->assertSame( 'publish', get_post_meta( $post_id, '_wp_trash_meta_status', true ) );
|
||||
$this->assertTrue( is_numeric( get_post_meta( $post_id, '_wp_trash_meta_time', true ) ) );
|
||||
$this->assertIsNumeric( get_post_meta( $post_id, '_wp_trash_meta_time', true ) );
|
||||
|
||||
foreach ( array_keys( $expected_actions ) as $action_name ) {
|
||||
$this->assertSame( $expected_actions[ $action_name ] + $action_counts[ $action_name ], did_action( $action_name ), "Action: $action_name" );
|
||||
|
||||
Reference in New Issue
Block a user