Changeset 9698 for trunk/tests/phpunit/testcases/core/functions.php
- Timestamp:
- 04/05/2015 06:18:13 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/testcases/core/functions.php
r9616 r9698 522 522 523 523 /** 524 * @group bp_core_get_root_option 525 */ 526 public function test_bp_core_get_root_option_with_unpopulated_cache() { 527 // Back up and unset global cache. 528 $old_options = buddypress()->site_options; 529 unset( buddypress()->site_options ); 530 531 $this->assertSame( $old_options['avatar_default'], bp_core_get_root_option( 'avatar_default' ) ); 532 533 // Clean up. 534 buddypress()->site_options = $old_options; 535 } 536 537 /** 538 * @group bp_core_get_root_option 539 */ 540 public function test_bp_core_get_root_option_with_populated_cache() { 541 // Back up and unset global cache. 542 $old_options = buddypress()->site_options; 543 buddypress()->site_options = bp_core_get_root_options(); 544 $expected = buddypress()->site_options['avatar_default']; 545 546 $this->assertSame( $expected, bp_core_get_root_option( 'avatar_default' ) ); 547 } 548 549 /** 524 550 * @group bp_core_add_root_component 525 551 */
Note: See TracChangeset
for help on using the changeset viewer.