Changeset 54088 for trunk/tests/phpunit/tests/term/termCounts.php
- Timestamp:
- 09/06/2022 10:03:10 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/term/termCounts.php
r52010 r54088 91 91 $term_count = get_term( get_option( 'default_category' ) )->count; 92 92 // Do not use shared fixture for this test as it relies on a new post. 93 $post_id = $this->factory()->post->create( array( 'post_status' => $post_status ) );93 $post_id = self::factory()->post->create( array( 'post_status' => $post_status ) ); 94 94 95 95 $expected = $term_count + $change; … … 245 245 add_filter( 'update_post_term_count_statuses', array( $this, 'add_custom_status_to_counted_statuses' ) ); 246 246 247 $post_id = $this->factory()->post->create( array( 'post_status' => $post_status ) );247 $post_id = self::factory()->post->create( array( 'post_status' => $post_status ) ); 248 248 wp_add_object_terms( $post_id, self::$attachment_term, 'wp_test_tax_counts' ); 249 249 $attachment_id = self::factory()->attachment->create_object( … … 297 297 $term_count = get_term( self::$attachment_term )->count; 298 298 // Do not use shared fixture for this test as it relies on a new post. 299 $post_id = $this->factory()->post->create( array( 'post_status' => $post_status ) );299 $post_id = self::factory()->post->create( array( 'post_status' => $post_status ) ); 300 300 wp_add_object_terms( $post_id, self::$attachment_term, 'wp_test_tax_counts' ); 301 301 $attachment_id = self::factory()->attachment->create_object(
Note: See TracChangeset
for help on using the changeset viewer.