You appear to be a bot. Output may be restricted
Description
Usage
Tests_Rewrite_OldDateRedirect::test_old_date_slug_redirect();
Parameters
Returns
void
Source
File name: wordpress-develop-tests/phpunit/tests/rewrite/oldDateRedirect.php
Lines:
1 to 19 of 19
public function test_old_date_slug_redirect() { $old_permalink = user_trailingslashit( get_permalink( self::$post_id ) ); $time = '2004-01-03 00:00:00'; wp_update_post( array( 'ID' => self::$post_id, 'post_date' => $time, 'post_date_gmt' => get_gmt_from_date( $time ), 'post_name' => 'bar-baz', ) ); $permalink = user_trailingslashit( get_permalink( self::$post_id ) ); $this->go_to( $old_permalink ); wp_old_slug_redirect(); $this->assertSame( $permalink, $this->old_date_redirect_url ); }