Changeset 44966 for trunk/tests/phpunit/tests/post/getBodyClass.php
- Timestamp:
- 03/21/2019 07:47:29 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/post/getBodyClass.php
r43571 r44966 203 203 $this->assertContains( 'attachment-jpeg', $class ); 204 204 } 205 206 /** 207 * @ticket 44005 208 * @group privacy 209 */ 210 public function test_privacy_policy_body_class() { 211 $page_id = self::factory()->post->create( 212 array( 213 'post_type' => 'page', 214 'post_title' => 'Privacy Policy', 215 ) 216 ); 217 update_option( 'wp_page_for_privacy_policy', $page_id ); 218 219 $this->go_to( get_permalink( $page_id ) ); 220 221 $class = get_body_class(); 222 223 $this->assertContains( 'privacy-policy', $class ); 224 $this->assertContains( 'page-template-default', $class ); 225 $this->assertContains( 'page', $class ); 226 $this->assertContains( "page-id-{$page_id}", $class ); 227 } 228 205 229 }
Note: See TracChangeset
for help on using the changeset viewer.