Skip to:
Content

BuddyPress.org

Changeset 9117


Ignore:
Timestamp:
11/03/2014 04:36:47 PM (10 years ago)
Author:
djpaul
Message:

Unit Tests, Groups: update the Group factory to handle false return values from groups_create_group.

It currently assumes that the group is always succesfully created, and this isn't true if creator_id is set to 0 (or if there is no logged in user).

See #5983

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/includes/factory.php

    r8958 r9117  
    7575
    7676        $group_id = groups_create_group( $args );
     77        if ( ! $group_id ) {
     78            return false;
     79        }
    7780
    7881        groups_update_groupmeta( $group_id, 'total_member_count', 1 );
Note: See TracChangeset for help on using the changeset viewer.