Webtest Fix
authorSudha Bisht <sudha.bisht@webaccessglobal.com>
Wed, 1 Jul 2015 13:59:24 +0000 (19:29 +0530)
committerSudha Bisht <sudha.bisht@webaccessglobal.com>
Wed, 1 Jul 2015 13:59:24 +0000 (19:29 +0530)
tests/phpunit/WebTest/Member/OnlineMembershipRenewTest.php

index 1e4d154e5202a44165686987336f5760b630de1f..2265e9864b1ddc0e16d9c7ba77b53f0e46b7c101 100644 (file)
@@ -867,7 +867,9 @@ class WebTest_Member_OnlineMembershipRenewTest extends CiviSeleniumTestCase {
     $this->assertEquals($membership['count'], 1);
     $membershipId = $membership['id'];
     $this->assertEquals($membership['values'][$membershipId]['membership_name'], $membershipTypeTitle);
-    $this->assertEquals($membership['values'][$membershipId]['status_id'], 1);
+    //CRM-16165: if membership contribution status is pending then membership status should be pending
+    $pendingStatus = CRM_Core_DAO::getFieldValue('CRM_Member_DAO_MembershipStatus', 'Pending', 'id', 'name');
+    $this->assertEquals($membership['values'][$membershipId]['status_id'], $pendingStatus);
 
     //check if the membership created is set to reccuring
     $recurringContributionId = $membership['values'][$membershipId]['contribution_recur_id'];