From: Peter Verthez Date: Sun, 12 Jan 2003 20:00:08 +0000 (+0000) Subject: Tests for moving xrefs in a list. X-Git-Url: https://git.dlugolecki.net.pl/?a=commitdiff_plain;h=647de05c085b571e29bf2f35a2c413d8c9fe003a;p=gedcom-parse.git Tests for moving xrefs in a list. --- diff --git a/t/output/update_gom.ref b/t/output/update_gom.ref index 17331ad..46075ac 100644 --- a/t/output/update_gom.ref +++ b/t/output/update_gom.ref @@ -166,6 +166,7 @@ Valid French revolution date: String: '@#DFRENCH R@ 16 PLUV 7' ERROR: Error: Cross-reference key '@FAM1@' is already in use ERROR: Error: Cross-reference key '@SUBMITTER@' is already in use +WARNING: Warning: Could not move struct of type xref_list Intermediate output: === HEADER === Source: diff --git a/t/src/update_gom.c b/t/src/update_gom.c index 87a65a1..dc48749 100644 --- a/t/src/update_gom.c +++ b/t/src/update_gom.c @@ -300,6 +300,18 @@ int test_record_add_delete_functions() xrl = gom_add_xref(&(fam1->children), ind4->xrefstr); if (!xrl) return 124; + result = gom_move_xref(MOVE_UP, &(fam1->children), ind4->xrefstr); + if (result != 0) return 127; + + result = gom_move_xref(MOVE_UP, &(fam1->children), ind4->xrefstr); + if (result != 0) return 128; + + result = gom_move_xref(MOVE_UP, &(fam1->children), ind4->xrefstr); + if (result != 0) return 129; + + result = gom_move_xref(MOVE_DOWN, &(fam1->children), ind4->xrefstr); + if (result != 0) return 130; + result = gom_remove_xref(&(fam1->children), ind3->xrefstr); if (result != 0) return 125;