WordPress.org

Make WordPress Core

Changeset 396 in tests


Ignore:
Timestamp:
08/04/2011 06:48:38 PM (7 years ago)
Author:
ryan
Message:

object_type is now an array.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wp-testcase/test_includes_taxonomy.php

    r366 r396  
    44class TestTaxonomyMeta extends _WPEmptyBlog {
    55    function test_get_post_taxonomies() {
    6         $this->assertEquals(array('category', 'post_tag'), get_object_taxonomies('post'));
     6        $this->assertEquals(array('category', 'post_tag', 'post_format'), get_object_taxonomies('post'));
    77    }
    88   
     
    2424            $tax = get_taxonomy($taxonomy);
    2525            // should return an object with the correct taxonomy object type
    26             $this->assertTrue( is_object($tax) );
    27             $this->assertEquals( 'post', $tax->object_type );
     26            $this->assertTrue( is_object( $tax ) );
     27            $this->assertTrue( is_array( $tax->object_type ) );
     28            $this->assertEquals( array( 'post' ), $tax->object_type );
    2829        }
    2930    }
     
    3435            // should return an object with the correct taxonomy object type
    3536            $this->assertTrue( is_object($tax) );
    36             $this->assertEquals( 'link', $tax->object_type );
     37            $this->assertTrue( is_array( $tax->object_type ) );
     38            $this->assertEquals( array( 'link' ), $tax->object_type );
    3739        }
    3840    }
Note: See TracChangeset for help on using the changeset viewer.