Changeset 42343 for trunk/tests/phpunit/tests/xmlrpc/wp/getPageList.php
- Timestamp:
- 11/30/2017 11:09:33 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/xmlrpc/wp/getPageList.php
r40417 r42343 8 8 9 9 public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { 10 self::$post_id = $factory->post->create( array( 11 'post_type' => 'page', 12 'post_author' => $factory->user->create( array( 13 'user_login' => 'author', 14 'user_pass' => 'author', 15 'role' => 'author' 16 ) ), 17 'post_date' => strftime( "%Y-%m-%d %H:%M:%S", strtotime( '+1 day' ) ), 18 ) ); 10 self::$post_id = $factory->post->create( 11 array( 12 'post_type' => 'page', 13 'post_author' => $factory->user->create( 14 array( 15 'user_login' => 'author', 16 'user_pass' => 'author', 17 'role' => 'author', 18 ) 19 ), 20 'post_date' => strftime( '%Y-%m-%d %H:%M:%S', strtotime( '+1 day' ) ), 21 ) 22 ); 19 23 } 20 24 … … 39 43 $this->assertNotIXRError( $results ); 40 44 41 foreach ( $results as $result ) {42 $page = get_post( $result->page_id );45 foreach ( $results as $result ) { 46 $page = get_post( $result->page_id ); 43 47 $date_gmt = strtotime( get_gmt_from_date( mysql2date( 'Y-m-d H:i:s', $page->post_date, false ), 'Ymd\TH:i:s' ) ); 44 48
Note: See TracChangeset
for help on using the changeset viewer.