Changeset 56607
- Timestamp:
- 09/18/2023 10:33:24 AM (21 months ago)
- Location:
- trunk/tests/phpunit
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/data/blocks/notice/block.json
r56587 r56607 32 32 }, 33 33 "blockHooks": { 34 "core/post-content": "before" 34 "tests/before": "before", 35 "tests/after": "after", 36 "tests/first-child": "firstChild", 37 "tests/last-child": "lastChild" 35 38 }, 36 39 "supports": { -
trunk/tests/phpunit/tests/blocks/register.php
r56587 r56607 646 646 ); 647 647 // @ticket 59346 648 $this->assertSame( 649 array( 'core/post-content' => 'before' ), 648 $this->assertSameSets( 649 array( 650 'tests/before' => 'before', 651 'tests/after' => 'after', 652 'tests/first-child' => 'first_child', 653 'tests/last-child' => 'last_child', 654 ), 650 655 $result->block_hooks, 651 656 'Block type should contain block hooks from metadata.' … … 1070 1075 $this->assertTrue( $actual ); 1071 1076 } 1077 1078 /** 1079 * @ticket 59346 1080 * 1081 * @covers ::register_block_type 1082 * 1083 * @expectedIncorrectUsage register_block_type_from_metadata 1084 */ 1085 public function test_register_block_hooks_targeting_itself() { 1086 $block_type = register_block_type( 1087 DIR_TESTDATA . '/blocks/hooked-block-error' 1088 ); 1089 1090 $this->assertSame( 1091 array( 'tests/other-block' => 'after' ), 1092 $block_type->block_hooks 1093 ); 1094 } 1072 1095 }
Note: See TracChangeset
for help on using the changeset viewer.