X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=tests%2Fphpunit%2FCRM%2FCore%2FBAO%2FLocationTest.php;h=f91874864abe8596de1444e8be60554712128d8a;hb=ddc7d6e7b3777edccc734a19dc9d59d837693fdc;hp=26fc750bc5ff4ccb0808e861f10f92f812c87043;hpb=060ea8f8e944292abc945b136c66cb7ccabd4fc1;p=civicrm-core.git diff --git a/tests/phpunit/CRM/Core/BAO/LocationTest.php b/tests/phpunit/CRM/Core/BAO/LocationTest.php index 26fc750bc5..f91874864a 100644 --- a/tests/phpunit/CRM/Core/BAO/LocationTest.php +++ b/tests/phpunit/CRM/Core/BAO/LocationTest.php @@ -275,7 +275,7 @@ class CRM_Core_BAO_LocationTest extends CiviUnitTestCase { //Now check DB for location elements. $searchParams = [ - 'id' => CRM_Utils_Array::value('address_id', $locElementIds), + 'id' => $locElementIds['address_id'] ?? NULL, 'location_type_id' => 1, 'is_primary' => 1, ]; @@ -294,7 +294,7 @@ class CRM_Core_BAO_LocationTest extends CiviUnitTestCase { $this->assertDBCompareValues('CRM_Core_DAO_Address', $searchParams, $compareParams); $searchParams = [ - 'id' => CRM_Utils_Array::value('email_id', $locElementIds), + 'id' => $locElementIds['email_id'] ?? NULL, 'location_type_id' => 1, 'is_primary' => 1, ]; @@ -302,7 +302,7 @@ class CRM_Core_BAO_LocationTest extends CiviUnitTestCase { $this->assertDBCompareValues('CRM_Core_DAO_Email', $searchParams, $compareParams); $searchParams = [ - 'id' => CRM_Utils_Array::value('phone_id', $locElementIds), + 'id' => $locElementIds['phone_id'] ?? NULL, 'location_type_id' => 1, 'is_primary' => 1, 'phone_type_id' => 1, @@ -311,7 +311,7 @@ class CRM_Core_BAO_LocationTest extends CiviUnitTestCase { $this->assertDBCompareValues('CRM_Core_DAO_Phone', $searchParams, $compareParams); $searchParams = [ - 'id' => CRM_Utils_Array::value('phone_2_id', $locElementIds), + 'id' => $locElementIds['phone_2_id'] ?? NULL, 'location_type_id' => 1, 'phone_type_id' => 2, ]; @@ -319,7 +319,7 @@ class CRM_Core_BAO_LocationTest extends CiviUnitTestCase { $this->assertDBCompareValues('CRM_Core_DAO_Phone', $searchParams, $compareParams); $searchParams = [ - 'id' => CRM_Utils_Array::value('im_id', $locElementIds), + 'id' => $locElementIds['im_id'] ?? NULL, 'location_type_id' => 1, 'is_primary' => 1, ];