--- src/plm/apitest/test_saPlmEntityGroupCreate.c | 3 +++ src/plm/apitest/test_saPlmEntityGroupDelete.c | 20 ++++++++++++++++++++ 2 files changed, 23 insertions(+)
diff --git a/src/plm/apitest/test_saPlmEntityGroupCreate.c b/src/plm/apitest/test_saPlmEntityGroupCreate.c index 8d88c35..538466e 100644 --- a/src/plm/apitest/test_saPlmEntityGroupCreate.c +++ b/src/plm/apitest/test_saPlmEntityGroupCreate.c @@ -72,6 +72,7 @@ extern void saPlmEntityGroupAdd_16(void); extern void saPlmEntityGroupDelete_01(void); extern void saPlmEntityGroupDelete_02(void); extern void saPlmEntityGroupDelete_03(void); +extern void saPlmEntityGroupDelete_04(void); void saPlmEntityGroupRemove_01(void); void saPlmEntityGroupRemove_02(void); void saPlmEntityGroupRemove_03(void); @@ -214,4 +215,6 @@ saPlmEntityGroupCreate_constructor(void) test_case_add( 2, saPlmEntityGroupDelete_03, "saPlmEntityGroupDelete_03 with invalid grouphandle after plmhandle got finalize - SA_AIS_ERR_BAD_HANDLE"); + test_case_add(2, saPlmEntityGroupDelete_04, + "saPlmEntityGroupDelete_04 with null pointer to grouphandle - SA_AIS_ERR_BAD_HANDLE"); } diff --git a/src/plm/apitest/test_saPlmEntityGroupDelete.c b/src/plm/apitest/test_saPlmEntityGroupDelete.c index f1fcde7..ed2b036 100644 --- a/src/plm/apitest/test_saPlmEntityGroupDelete.c +++ b/src/plm/apitest/test_saPlmEntityGroupDelete.c @@ -51,3 +51,23 @@ void saPlmEntityGroupDelete_03(void) rc = saPlmEntityGroupDelete(entityGroupHandle); test_validate(rc, SA_AIS_ERR_BAD_HANDLE); } + +void saPlmEntityGroupDelete_04(void) +{ + SaPlmCallbacksT plms_cbks; + plms_cbks.saPlmReadinessTrackCallback = &TrackCallbackT; + safassert(saPlmInitialize(&plmHandle, &plms_cbks, &PlmVersion), + SA_AIS_OK); + safassert(saPlmEntityGroupCreate(plmHandle, &entityGroupHandle), + SA_AIS_OK); + safassert(saPlmEntityGroupAdd(entityGroupHandle, &f120_slot_1_dn, + entityNamesNumber, + SA_PLM_GROUP_SINGLE_ENTITY), + SA_AIS_OK); + safassert(saPlmEntityGroupRemove(entityGroupHandle, &f120_slot_1_dn, + entityNamesNumber), + SA_AIS_OK); + safassert(saPlmFinalize(plmHandle), SA_AIS_OK); + rc = saPlmEntityGroupDelete(0); + test_validate(rc, SA_AIS_ERR_BAD_HANDLE); +} -- 2.7.4 _______________________________________________ Opensaf-devel mailing list Opensaf-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/opensaf-devel