Tests: Use factory method to generate fixtures for wp_unique_post_slug()
tests.
Props mintindeed. See #20419. git-svn-id: https://develop.svn.wordpress.org/trunk@37443 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
b34c03c5b0
commit
55961a5613
@ -31,7 +31,7 @@ class Tests_Post_WpUniquePostSlug extends WP_UnitTestCase {
|
||||
'post_title' => $post_title,
|
||||
);
|
||||
|
||||
$id = $this->post_ids[] = wp_insert_post( $post );
|
||||
$id = $this->post_ids[] = self::factory()->post->create( $post );
|
||||
}
|
||||
|
||||
$post = get_post( $id );
|
||||
|
Loading…
Reference in New Issue
Block a user