l10n: Update translation catalogues
[libisds.git] / test / offline / isds_PersonName_free.c
blob9a78b9e8b9cb3ee9886ac740af5ccd777e7b417e
1 #include "../test.h"
2 #include "isds.h"
4 static int test_isds_PersonName_free(
5 struct isds_PersonName **PersonName) {
6 isds_PersonName_free(PersonName);
7 if (NULL == PersonName) PASS_TEST;
9 if (NULL != *PersonName)
10 FAIL_TEST("isds_PersonName_free() did not null pointer");
12 PASS_TEST;
16 int main(void) {
18 INIT_TEST("isds_PersonName_free()");
19 if (isds_init())
20 ABORT_UNIT("isds_init() failed");
22 struct isds_PersonName *PersonName = NULL;
23 TEST("NULL", test_isds_PersonName_free, NULL);
24 TEST("*NULL", test_isds_PersonName_free, &PersonName);
26 TEST_CALLOC(PersonName);
27 TEST("Empty structure", test_isds_PersonName_free, &PersonName);
29 TEST_CALLOC(PersonName);
30 TEST_FILL_STRING(PersonName->pnFirstName);
31 TEST_FILL_STRING(PersonName->pnMiddleName);
32 TEST_FILL_STRING(PersonName->pnLastName);
33 TEST_FILL_STRING(PersonName->pnLastNameAtBirth);
34 TEST("Full structure", test_isds_PersonName_free, &PersonName);
36 isds_cleanup();
37 SUM_TEST();