Changeset 9139 for trunk/tests/phpunit/testcases/activity/functions.php
- Timestamp:
- 11/14/2014 02:01:18 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/testcases/activity/functions.php
r9052 r9139 453 453 add_filter( 'bp_is_username_compatibility_mode', '__return_false' ); 454 454 455 $u = $this-> create_user( array(455 $u = $this->factory->user->create( array( 456 456 'user_login' => 'foo bar baz', 457 457 'user_nicename' => 'foo-bar-baz', … … 469 469 add_filter( 'bp_is_username_compatibility_mode', '__return_true' ); 470 470 471 $u1 = $this-> create_user( array(471 $u1 = $this->factory->user->create( array( 472 472 'user_login' => 'foo bar baz', 473 473 'user_nicename' => 'foo-bar-baz', 474 474 ) ); 475 475 476 $u2 = $this-> create_user( array(476 $u2 = $this->factory->user->create( array( 477 477 'user_login' => 'foo.bar.baz', 478 478 'user_nicename' => 'foo-bar-baz', … … 491 491 add_filter( 'bp_is_username_compatibility_mode', '__return_false' ); 492 492 493 $u = $this-> create_user( array(493 $u = $this->factory->user->create( array( 494 494 'user_login' => 'foo bar baz', 495 495 'user_nicename' => 'foo-bar-baz', … … 508 508 509 509 // all spaces are hyphens 510 $u1 = $this-> create_user( array(510 $u1 = $this->factory->user->create( array( 511 511 'user_login' => 'foo bar baz', 512 512 'user_nicename' => 'foobarbaz', … … 514 514 515 515 // no spaces are hyphens 516 $u2 = $this-> create_user( array(516 $u2 = $this->factory->user->create( array( 517 517 'user_login' => 'foo-bar-baz-1', 518 518 'user_nicename' => 'foobarbaz-1', … … 520 520 521 521 // some spaces are hyphens 522 $u3 = $this-> create_user( array(522 $u3 = $this->factory->user->create( array( 523 523 'user_login' => 'foo bar-baz 2', 524 524 'user_nicename' => 'foobarbaz-2', 525 525 ) ); 526 526 527 $u4 = $this-> create_user( array(527 $u4 = $this->factory->user->create( array( 528 528 'user_login' => 'foo.bar.baz', 529 529 'user_nicename' => 'foo-bar-baz', … … 543 543 */ 544 544 public function test_bp_activity_format_activity_action_activity_update() { 545 $u = $this-> create_user();545 $u = $this->factory->user->create(); 546 546 $a = $this->factory->activity->create( array( 547 547 'component' => buddypress()->activity->id, … … 562 562 */ 563 563 public function test_bp_activity_format_activity_action_activity_comment() { 564 $u = $this-> create_user();564 $u = $this->factory->user->create(); 565 565 $a = $this->factory->activity->create( array( 566 566 'component' => buddypress()->activity->id, … … 747 747 */ 748 748 public function test_add_user_favorite_already_favorited() { 749 $u = $this-> create_user();749 $u = $this->factory->user->create(); 750 750 $a = $this->factory->activity->create(); 751 751 … … 762 762 */ 763 763 public function test_add_user_favorite_not_yet_favorited() { 764 $u = $this-> create_user();764 $u = $this->factory->user->create(); 765 765 $a = $this->factory->activity->create(); 766 766 $this->assertTrue( bp_activity_add_user_favorite( $a, $u ) ); … … 772 772 */ 773 773 public function test_remove_user_favorite_bad_activity_id() { 774 $u1 = $this-> create_user();775 $u2 = $this-> create_user();774 $u1 = $this->factory->user->create(); 775 $u2 = $this->factory->user->create(); 776 776 $a = $this->factory->activity->create(); 777 777 … … 805 805 */ 806 806 public function test_bp_activity_post_update_success() { 807 $u = $this-> create_user();807 $u = $this->factory->user->create(); 808 808 809 809 $a = bp_activity_post_update( array(
Note: See TracChangeset
for help on using the changeset viewer.