Skip to:
Content

BuddyPress.org

Changeset 9137


Ignore:
Timestamp:
11/13/2014 04:08:47 AM (10 years ago)
Author:
boonebgorges
Message:

Better current user setting during total_group_count tests.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/testcases/groups/functions.php

    r9121 r9137  
    88    protected $old_current_user_id = 0;
    99
     10    public function setUp() {
     11        parent::setUp();
     12        $this->old_current_user = get_current_user_id();
     13    }
     14
     15    public function tearDown() {
     16        parent::tearDown();
     17        $this->set_current_user( $this->old_current_user );
     18    }
    1019
    1120    public function test_creating_new_group_as_authenticated_user() {
    12         $this->old_current_user_id = get_current_user_id();
    13 
    1421        $u = $this->create_user();
    1522        wp_set_current_user( $u );
Note: See TracChangeset for help on using the changeset viewer.