Changeset 35800 for trunk/tests/phpunit/tests/post.php
- Timestamp:
- 12/06/2015 09:57:59 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/post.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/post.php
r35705 r35800 1190 1190 1191 1191 /** 1192 * If a post is updated without providing a post_name param, 1193 * a new slug should not be generated. 1194 * 1195 * @ticket 34865 1196 */ 1197 function test_post_updates_without_slug_provided() { 1198 $post_id = self::factory()->post->create( array( 1199 'post_title' => 'Stuff', 1200 'post_status' => 'publish' 1201 ) ); 1202 1203 $data = array( 1204 'ID' => $post_id, 1205 'post_title' => 'Stuff and Things' 1206 ); 1207 1208 wp_insert_post( $data ); 1209 1210 $updated_post = get_post( $post_id ); 1211 // Ensure changing the post_title didn't modify the post_name. 1212 $this->assertEquals('stuff', $updated_post->post_name); 1213 } 1214 1215 /** 1192 1216 * @ticket 32585 1193 1217 */
Note: See TracChangeset
for help on using the changeset viewer.