Changeset 57660 for trunk/tests/phpunit/tests/blocks/insertHookedBlocks.php
- Timestamp:
- 02/20/2024 09:25:09 AM (10 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/blocks/insertHookedBlocks.php
r57627 r57660 111 111 ); 112 112 113 $filter = function ( $parsed_hooked_block, $ relative_position, $parsed_anchor_block ) {113 $filter = function ( $parsed_hooked_block, $hooked_block_type, $relative_position, $parsed_anchor_block ) { 114 114 // Is the hooked block adjacent to the anchor block? 115 115 if ( 'before' !== $relative_position && 'after' !== $relative_position ) { … … 125 125 return $parsed_hooked_block; 126 126 }; 127 add_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter, 10, 3);127 add_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter, 10, 4 ); 128 128 $actual = insert_hooked_blocks( $anchor_block, 'after', self::HOOKED_BLOCKS, array() ); 129 remove_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter , 10, 3);129 remove_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter ); 130 130 131 131 $this->assertSame( … … 173 173 add_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter, 10, 3 ); 174 174 $actual = insert_hooked_blocks( $anchor_block, 'after', self::HOOKED_BLOCKS, array() ); 175 remove_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter , 10, 3);175 remove_filter( 'hooked_block_' . self::HOOKED_BLOCK_TYPE, $filter ); 176 176 177 177 $this->assertSame(
Note: See TracChangeset
for help on using the changeset viewer.