- Timestamp:
- 01/26/2023 11:01:10 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/theme/wpGetGlobalStylesheet.php
r54214 r55148 271 271 ); 272 272 } 273 /** 274 * Tests that switching themes recalculates the stylesheet. 275 * 276 * @ticket 56970 277 */ 278 public function test_switching_themes_should_recalculate_stylesheet() { 279 $stylesheet_for_default_theme = wp_get_global_stylesheet(); 280 switch_theme( 'block-theme' ); 281 $stylesheet_for_block_theme = wp_get_global_stylesheet(); 282 switch_theme( WP_DEFAULT_THEME ); 283 284 $this->assertStringNotContainsString( '--wp--preset--font-size--custom: 100px;', $stylesheet_for_default_theme, 'custom font size (100px) not present for default theme' ); 285 $this->assertStringContainsString( '--wp--preset--font-size--custom: 100px;', $stylesheet_for_block_theme, 'custom font size (100px) is present for block theme' ); 286 } 273 287 }
Note: See TracChangeset
for help on using the changeset viewer.