6 function custom_group_create_example(){
8 'title' => 'Test_Group_1',
9 'name' => 'test_group_1',
14 'collapse_display' => 1,
16 'help_pre' => 'This is Pre Help For Test Group 1',
17 'help_post' => 'This is Post Help For Test Group 1',
22 $result = civicrm_api( 'custom_group','create',$params );
28 * Function returns array of result expected from previous function
30 function custom_group_create_expectedresult(){
32 $expectedResult = array(
40 'name' => 'test_group_1',
41 'title' => 'Test_Group_1',
42 'extends' => 'Individual',
43 'extends_entity_column_id' => 'null',
44 'extends_entity_column_value' => 'null',
46 'collapse_display' => '1',
47 'help_pre' => 'This is Pre Help For Test Group 1',
48 'help_post' => 'This is Post Help For Test Group 1',
51 'table_name' => 'civicrm_value_test_group_1_1',
54 'max_multiple' => 'null',
55 'collapse_adv_display' => '',
57 'created_date' => '20120130621222105',
63 return $expectedResult ;
68 * This example has been generated from the API test suite. The test that created it is called
70 * testCustomGroupCreate and can be found in
71 * http://svn.civicrm.org/civicrm/trunk/tests/phpunit/CiviTest/api/v3/CustomGroupTest.php
73 * You can see the outcome of the API tests at
74 * http://tests.dev.civicrm.org/trunk/results-api_v3
76 * To Learn about the API read
77 * http://book.civicrm.org/developer/current/techniques/api/
79 * and review the wiki at
80 * http://wiki.civicrm.org/confluence/display/CRMDOC/CiviCRM+Public+APIs
82 * Read more about testing here
83 * http://wiki.civicrm.org/confluence/display/CRM/Testing
85 * API Standards documentation:
86 * http://wiki.civicrm.org/confluence/display/CRM/API+Architecture+Standards