Only Ignore Execptions thrown by the When package when its the UnitTests
authorSeamus Lee <seamuslee001@gmail.com>
Wed, 11 Sep 2019 07:20:12 +0000 (17:20 +1000)
committerSeamus Lee <seamuslee001@gmail.com>
Thu, 3 Oct 2019 08:07:32 +0000 (18:07 +1000)
CRM/Core/BAO/RecurringEntity.php

index a74f8ca35e8ed5846db846d55aa8b2d1af50bfdb..e0275b469f6b7886aaa94ad22b0cd612d699a27f 100644 (file)
@@ -345,7 +345,9 @@ class CRM_Core_BAO_RecurringEntity extends CRM_Core_DAO_RecurringEntity {
 
       $count = 1;
       try {
-        $this->recursion->RFC5545_COMPLIANT = When::IGNORE;
+        if (CRM_Core_Config::singleton()->userFramework == 'UnitTests') {
+          $this->recursion->RFC5545_COMPLIANT = When::IGNORE;
+        }
         $this->recursion->generateOccurrences();
       }
       catch (Exception $e) {