Changeset 35242 for trunk/tests/phpunit/tests/post/objects.php
- Timestamp:
- 10/17/2015 06:02:16 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/post/objects.php (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/post/objects.php
r35225 r35242 7 7 8 8 function test_get_post() { 9 $id = self:: $factory->post->create();9 $id = self::factory()->post->create(); 10 10 11 11 $post = get_post( $id ); … … 68 68 69 69 function test_get_post_ancestors() { 70 $parent_id = self:: $factory->post->create();71 $child_id = self:: $factory->post->create();72 $grandchild_id = self:: $factory->post->create();70 $parent_id = self::factory()->post->create(); 71 $child_id = self::factory()->post->create(); 72 $grandchild_id = self::factory()->post->create(); 73 73 $updated = wp_update_post( array( 'ID' => $child_id, 'post_parent' => $parent_id ) ); 74 74 $this->assertEquals( $updated, $child_id ); … … 100 100 101 101 function test_get_post_category_property() { 102 $post_id = self:: $factory->post->create();102 $post_id = self::factory()->post->create(); 103 103 $post = get_post( $post_id ); 104 104 … … 119 119 120 120 function test_get_tags_input_property() { 121 $post_id = self:: $factory->post->create();121 $post_id = self::factory()->post->create(); 122 122 $post = get_post( $post_id ); 123 123 … … 136 136 137 137 function test_get_page_template_property() { 138 $post_id = self:: $factory->post->create();138 $post_id = self::factory()->post->create(); 139 139 $post = get_post( $post_id ); 140 140 … … 156 156 157 157 function test_get_post_filter() { 158 $post = get_post( self:: $factory->post->create( array(158 $post = get_post( self::factory()->post->create( array( 159 159 'post_title' => "Mary's home" 160 160 ) ) ); … … 179 179 180 180 function test_get_post_identity() { 181 $post = get_post( self:: $factory->post->create() );181 $post = get_post( self::factory()->post->create() ); 182 182 183 183 $post->foo = 'bar'; … … 188 188 189 189 function test_get_post_array() { 190 $id = self:: $factory->post->create();190 $id = self::factory()->post->create(); 191 191 192 192 $post = get_post( $id, ARRAY_A ); … … 203 203 global $wpdb; 204 204 205 $id = self:: $factory->post->create();205 $id = self::factory()->post->create(); 206 206 wp_cache_delete( $id, 'posts' ); 207 207
Note: See TracChangeset
for help on using the changeset viewer.