Skip to:
Content

BuddyPress.org

Ticket #6462: 6462.04.patch

File 6462.04.patch, 1.4 KB (added by dcavins, 9 years ago)

Check for draft invites when checking that invites have been removed.

  • tests/phpunit/testcases/groups/class-bp-groups-member.php

    diff --git tests/phpunit/testcases/groups/class-bp-groups-member.php tests/phpunit/testcases/groups/class-bp-groups-member.php
    index 30b547a..ef8e61f 100644
    class BP_Tests_BP_Groups_Member_TestCases extends BP_UnitTestCase { 
    372372                // The invitation should be removed.
    373373                self::invite_user_to_group( $u2, $g, $u1 );
    374374                groups_reject_invite( $u2, $g );
    375                 $u2_has_invite = groups_check_user_has_invite( $u2, $g );
     375                $u2_has_invite = groups_check_user_has_invite( $u2, $g, $type = 'all' );
    376376                $this->assertEquals( 0, $u2_has_invite );
    377377        }
    378378
    class BP_Tests_BP_Groups_Member_TestCases extends BP_UnitTestCase { 
    436436                // The invitation should be removed.
    437437                self::invite_user_to_group( $u2, $g, $u1 );
    438438                groups_delete_invite( $u2, $g );
    439                 $u2_has_invite = groups_check_user_has_invite( $u2, $g );
     439                $u2_has_invite = groups_check_user_has_invite( $u2, $g, $type = 'all' );
    440440                $this->assertEquals( 0, $u2_has_invite );
    441441        }
    442442
    class BP_Tests_BP_Groups_Member_TestCases extends BP_UnitTestCase { 
    533533                // The invitation should be removed.
    534534                self::invite_user_to_group( $u2, $g, $u1 );
    535535                groups_uninvite_user( $u2, $g );
    536                 $u2_has_invite = groups_check_user_has_invite( $u2, $g );
     536                $u2_has_invite = groups_check_user_has_invite( $u2, $g, $type = 'all' );
    537537                $this->assertEquals( 0, $u2_has_invite );
    538538        }
    539539