| 92 | |
| 93 | /** |
| 94 | * @ticket 36595 |
| 95 | */ |
| 96 | function test_set_post_modified() { |
| 97 | $wp_test = array( |
| 98 | 'post_title' => 'test', |
| 99 | 'post_content' => 'test', |
| 100 | 'post_status' => 'publish', |
| 101 | 'post_type' => 'test', |
| 102 | 'post_author' => 1, |
| 103 | 'post_date' => '2015-01-22 22:00:12', |
| 104 | 'post_modified' => '2016-04-18 12:12:12', |
| 105 | 'comment_status' => 'closed' |
| 106 | ); |
| 107 | $post_id = wp_insert_post( $wp_test ); |
| 108 | |
| 109 | $the_post = get_post( $post_id ); |
| 110 | |
| 111 | $this->assertEquals( $wp_test['post_date'], $the_post->post_date ); |
| 112 | $this->assertEquals( $wp_test['post_modified'], $the_post->post_modified ); |
| 113 | |