Changeset 50565 for trunk/tests/phpunit/tests/term/getTermLink.php
- Timestamp:
- 03/23/2021 01:53:50 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/term/getTermLink.php
r49108 r50565 103 103 $this->assertContains( 'taxonomy=wptests_tax2', $actual ); 104 104 $this->assertContains( 'term=bar', $actual ); 105 } 106 107 /** 108 * @ticket 52882 109 */ 110 public function test_taxonomy_with_rewrite_false_and_custom_permalink_structure() { 111 $this->set_permalink_structure( '/%year%/%monthnum%/%day%/%postname%/' ); 112 113 register_taxonomy( 114 'wptests_tax2', 115 'post', 116 array( 117 'rewrite' => false, 118 ) 119 ); 120 121 add_permastruct( 'wptests_tax2', 'foo/%wptests_tax2%' ); 122 123 $t = self::factory()->term->create( 124 array( 125 'taxonomy' => 'wptests_tax2', 126 'slug' => 'bar', 127 ) 128 ); 129 130 $actual = get_term_link( $t, 'wptests_tax2' ); 131 132 remove_permastruct( 'wptests_tax2' ); 133 134 $this->assertContains( '/foo/bar/', $actual ); 105 135 } 106 136
Note: See TracChangeset
for help on using the changeset viewer.