Changeset 56994 for trunk/tests/phpunit/tests/blocks/render.php
- Timestamp:
- 10/24/2023 08:49:38 AM (15 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/blocks/render.php
r56547 r56994 219 219 $html = do_blocks( self::strip_r( file_get_contents( $html_path ) ) ); 220 220 // If blocks opt into Gutenberg's layout implementation 221 // the container will receive an add ed classname of `wp_unique_id( 'wp-container-' )`221 // the container will receive an additional, unique classname based on "wp-container-[blockname]-layout" 222 222 // so we need to normalize the random id. 223 $normalized_html = preg_replace( '/wp-container- \d+/', 'wp-container-1', $html );223 $normalized_html = preg_replace( '/wp-container-[a-z-]+\d+/', 'wp-container-1', $html ); 224 224 225 225 // The gallery block uses a unique class name of `wp_unique_id( 'wp-block-gallery-' )`
Note: See TracChangeset
for help on using the changeset viewer.