Make WordPress Core


Ignore:
Timestamp:
04/15/2017 08:19:49 PM (7 years ago)
Author:
johnbillion
Message:

Build/Test Tools: Partial merge of [30283] into the 4.0 branch to avoid PHP notices that cause a test failure.

See #30284

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/4.0/tests/phpunit/tests/feed/rss2.php

    r25002 r40449  
    111111
    112112            // author
    113             $creator = xml_find($items[$i]['child'], 'dc:creator');
    114             $this->assertEquals($this->author->user_nicename, $creator[0]['content']);
     113            $creator = xml_find( $items[$i]['child'], 'dc:creator' );
     114            $user = new WP_User( $posts[$i]->post_author );
     115            $this->assertEquals( $user->user_login, $creator[0]['content'] );
    115116
    116117            // categories (perhaps multiple)
    117118            $categories = xml_find($items[$i]['child'], 'category');
    118             $cat_ids = wp_get_post_categories($post->ID);
     119            $cat_ids = wp_get_post_categories($posts[$i]->ID);
    119120            if (empty($cat_ids))    $cat_ids = array(1);
    120121            // should be the same number of categories
Note: See TracChangeset for help on using the changeset viewer.