Commit | Line | Data |
---|---|---|
6a488035 | 1 | <?php |
6a488035 TO |
2 | |
3 | function group_contact__example() { | |
4 | $params = array( | |
5 | 'contact_id' => '1', | |
6 | 'group_id' => '1', | |
7 | 'version' => '3', | |
8 | ); | |
9 | require_once 'api/api.php'; | |
10 | $result = civicrm_api('group_contact', '', $params); | |
11 | ||
12 | return $result; | |
13 | } | |
14 | ||
15 | /* | |
16 | * Function returns array of result expected from previous function | |
17 | */ | |
18 | function group_contact__expectedresult() { | |
19 | ||
20 | $expectedResult = array( | |
21 | 'is_error' => '0', | |
22 | 'version' => '3', | |
23 | 'count' => '4', | |
24 | 'values' => array( | |
25 | 'is_error' => '0', 'not_removed' => '0', 'removed' => '1', 'total_count' => '1', | |
26 | ), | |
27 | ); | |
28 | ||
29 | return $expectedResult; | |
30 | } | |
31 |