- Timestamp:
- 07/14/2021 08:52:00 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/testcases/core/class-bp-component.php
r12994 r12998 2 2 3 3 include_once BP_TESTS_DIR . '/assets/bp-rest-api-controllers.php'; 4 include_once BP_TESTS_DIR . '/assets/class-bptest-component.php'; 4 5 5 6 /** … … 69 70 ) ); 70 71 } 72 73 /** 74 * @group bp_blocks 75 */ 76 public function test_component_block_globals() { 77 $expected = array( 78 'dynamic_widget_classname' => 'widget_example_classname', 79 ); 80 81 $example = new BPTest_Component( 82 array( 83 'globals' => array( 84 'block_globals' => array( 85 'bp/example-block' => $expected, 86 ) 87 ), 88 ) 89 ); 90 91 do_action( 'bp_setup_globals' ); 92 93 $this->assertEquals( $expected, $example->block_globals['bp/example-block']->props ); 94 } 71 95 }
Note: See TracChangeset
for help on using the changeset viewer.