add code to help track down intermittant test fail
authoreileenmcnaugton <eileen@fuzion.co.nz>
Wed, 9 Dec 2015 03:47:28 +0000 (16:47 +1300)
committereileenmcnaugton <eileen@fuzion.co.nz>
Wed, 9 Dec 2015 03:47:28 +0000 (16:47 +1300)
CRM/Core/LegacyErrorHandler.php
CRM/Member/BAO/Membership.php

index a25dc320c7e42d04808618891b51c1358cf44a3c..837fbc34c4ae7ba3216541d1a13b05b9f6cfaa8f 100644 (file)
@@ -26,6 +26,7 @@ class CRM_Core_LegacyErrorHandler {
       // you should log a ticket for it to be removed with details about the form you were on.
       if (!empty($params['legacy_redirect_path'])) {
         if (CRM_Utils_System::isDevelopment()) {
+          $intentionalENotice = "How did you get HERE?! - Please log in JIRA";
           // here we could set a message telling devs to log it per above
         }
         CRM_Utils_System::redirect($params['legacy_redirect_path'], $params['legacy_redirect_query']);
index 807b26cd7ed0dbbfe2bdb91b31f249f7b77f5d26..21d8cc2469f8e6412d00907e0198bd2392dc5742 100644 (file)
@@ -272,7 +272,11 @@ class CRM_Member_BAO_Membership extends CRM_Member_DAO_Membership {
           'legacy_redirect_path' => 'civicrm/contact/view',
           'legacy_redirect_query' => "reset=1&force=1&cid={$params['contact_id']}&selectedChild=member",
         );
-        throw new CRM_Core_Exception(ts('The membership cannot be saved because the status cannot be calculated.'), 0, $errorParams);
+        throw new CRM_Core_Exception(ts(
+          "The membership cannot be saved because the status cannot be calculated for start_date: $start_date end_date $end_date join_date $join_date as at " . date('Y-m-d H:i:s')),
+          0,
+          $errorParams
+        );
       }
       $params['status_id'] = $calcStatus['id'];
     }