Add UFField to syntaxConformanceTest
authorColeman Watts <coleman@civicrm.org>
Mon, 22 Apr 2019 12:22:13 +0000 (08:22 -0400)
committerColeman Watts <coleman@civicrm.org>
Mon, 22 Apr 2019 20:31:16 +0000 (16:31 -0400)
tests/phpunit/api/v3/SyntaxConformanceTest.php

index 64dbdcda3f65f1735da6f0eb0b4e38b7a1802931..e22e8eea0c77e7157314bcd9c809e5329dcfc20e 100644 (file)
@@ -498,7 +498,6 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase {
       'Profile',
       'CustomValue',
       'UFJoin',
-      'UFField',
       'Relationship',
       'RelationshipType',
       'Note',
@@ -736,6 +735,27 @@ class api_v3_SyntaxConformanceTest extends CiviUnitTestCase {
           'ignore_severity',
         ),
       ),
+      'UFField' => array(
+        'cant_update' => array(
+          // These fields get auto-adjusted by the BAO prior to saving
+          'weight',
+          'location_type_id',
+          'phone_type_id',
+          'website_type_id',
+          // Not a real field
+          'option.autoweight',
+        ),
+        'break_return' => array(
+          // These fields get auto-adjusted by the BAO prior to saving
+          'weight',
+          'field_type',
+          'location_type_id',
+          'phone_type_id',
+          'website_type_id',
+          // Not a real field
+          'option.autoweight',
+        ),
+      ),
       'JobLog' => array(
         // For better or worse triggers override.
         'break_return' => ['run_time'],