Merge branch 'JohnFF-patch-1'
[civicrm-core.git] / tests / phpunit / api / v3 / GrantTest.php
index 6a262089d26d517d488e07db3127d7305ea23895..5909e5ee8faf9b91e5aa68fd247477bb1fd150ed 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /*
  +--------------------------------------------------------------------+
- | CiviCRM version 4.4                                                |
+ | CiviCRM version 4.5                                                |
  +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2013                                |
+ | Copyright CiviCRM LLC (c) 2004-2014                                |
  +--------------------------------------------------------------------+
  | This file is a part of CiviCRM.                                    |
  |                                                                    |
@@ -84,7 +84,7 @@ class api_v3_GrantTest extends CiviUnitTestCase {
     $ids['custom_group_id'] = $result['id'];
     $customTable = $result['values'][$result['id']]['table_name'];
     $result = $this->customFieldCreate(array(
-      'html_type' => 'Checkbox',
+      'html_type' => 'CheckBox',
       'custom_group_id' => $ids['custom_group_id'],
       'option_values' => array(
         array('label' => 'my valley', 'value' => 'valley', 'is_active' => TRUE, 'weight' => 1),
@@ -207,7 +207,7 @@ class api_v3_GrantTest extends CiviUnitTestCase {
         case CRM_Utils_Type::T_INT:
           // probably created with a 1
           $entity[$field] = 2;
-          if (CRM_Utils_Array::value('FKClassName', $specs)) {
+          if (!empty($specs['FKClassName'])) {
             $entity[$field] = empty($entity2[$field]) ? $entity2[$specs]['uniqueName'] : $entity2[$field];
           }
           break;