Changeset 34681 for trunk/tests/phpunit/tests/xmlrpc/wp/newPost.php
- Timestamp:
- 09/29/2015 04:04:16 AM (10 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/xmlrpc/wp/newPost.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/xmlrpc/wp/newPost.php
r29063 r34681 384 384 } 385 385 386 /** 387 * @ticket 30429 388 */ 389 function test_post_date_timezone_conversion() { 390 $tz = get_option( 'timezone_string' ); 391 update_option( 'timezone_string', 'America/New_York' ); 392 393 $this->make_user_by_role( 'author' ); 394 $date_string = '1984-01-11 05:00:00'; 395 $post = array( 'post_title' => 'test', 'post_content' => 'test', 'post_date' => $date_string ); 396 $result = $this->myxmlrpcserver->wp_newPost( array( 1, 'author', 'author', $post ) ); 397 $fetched_post = get_post( $result ); 398 399 update_option( 'timezone_string', $tz ); 400 401 $this->assertStringMatchesFormat( '%d', $result ); 402 $this->assertEquals( $date_string , $fetched_post->post_date ); 403 } 386 404 }
Note: See TracChangeset
for help on using the changeset viewer.