Changeset 35242 for trunk/tests/phpunit/tests/term/getTermField.php
- Timestamp:
- 10/17/2015 06:02:16 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/term/getTermField.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/term/getTermField.php
r35225 r35242 18 18 */ 19 19 public function test_get_term_field_should_not_return_error_for_empty_taxonomy() { 20 $term = self:: $factory->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) );20 $term = self::factory()->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) ); 21 21 22 22 $found = get_term_field( 'taxonomy', $term->term_id, '' ); … … 29 29 */ 30 30 public function test_get_term_field_supplying_a_taxonomy() { 31 $term = self:: $factory->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) );31 $term = self::factory()->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) ); 32 32 33 33 $found = get_term_field( 'taxonomy', $term->term_id, $term->taxonomy ); … … 39 39 */ 40 40 public function test_get_term_field_supplying_no_taxonomy() { 41 $term = self:: $factory->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) );41 $term = self::factory()->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) ); 42 42 43 43 $found = get_term_field( 'taxonomy', $term->term_id ); … … 49 49 */ 50 50 public function test_get_term_field_should_accept_a_WP_Term_object_or_a_term_id() { 51 $term = self:: $factory->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) );51 $term = self::factory()->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) ); 52 52 53 53 $this->assertInstanceOf( 'WP_Term', $term ); … … 60 60 */ 61 61 public function test_get_term_field_invalid_taxonomy_should_return_WP_Error() { 62 $term = self:: $factory->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) );62 $term = self::factory()->term->create_and_get( array( 'taxonomy' => $this->taxonomy ) ); 63 63 64 64 $found = get_term_field( 'taxonomy', $term, 'foo-taxonomy' );
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)