Skip to content

Commit

Permalink
RDKB-51761 Test scenario to cover multiple rbus_open() call
Browse files Browse the repository at this point in the history
Reason for change: Need to cover test app and unit test to have a test cases which covers multiple rbus_open() with same component name without rbus_close() call.
The test scenario should also cover regDataElements, rbus_set, rbus_get, addrow and methodinvoke after doing multiple rbus_open() function call
Test Procedure: Start rtrouted and ./rbus_test.sh
Risks: Medium
Priority: P1

Signed-off-by: Deepak_m <[email protected]>
  • Loading branch information
dm097 committed Nov 7, 2023
1 parent 845a61d commit 611ad5f
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,6 @@ int main(int argc, char *argv[])
{
printf("multiRbusOpenMethodConsumer: rbusMethod_Invoke(Device.Methods.SimpleMethod()) using handle2 return err:%d\n", rc2);
}
rbusObject_Release(inParams1);
rbusObject_Release(inParams2);

if(rc1 == RBUS_ERROR_SUCCESS)
{
Expand All @@ -122,6 +120,8 @@ int main(int argc, char *argv[])
rbusObject_fwrite(outParams2, 1, stdout);
rbusObject_Release(outParams2);
}
rbusObject_Release(inParams1);
rbusObject_Release(inParams2);

/*Test to check the Outparams error msg handling
This testcase reads the provider specific error code and prints it.
Expand Down Expand Up @@ -183,7 +183,6 @@ int main(int argc, char *argv[])

rc1 = rbusMethod_InvokeAsync(handle1, "Device.Methods.AsyncMethod()", inParams1, asyncMethodHandler, 0);

rbusObject_Release(inParams1);

printf("multiRbusOpenMethodConsumer: rbusMethod_InvokeAsync(Device.Methods.AsyncMethod()) for handle1 %s with err :%d\n", rc1 == RBUS_ERROR_INVALID_HANDLE ? "success" : "fail",rc1);

Expand All @@ -200,7 +199,6 @@ int main(int argc, char *argv[])
rbusObject_fwrite(outParams2, 1, stdout);
rbusObject_Release(outParams2);
}
rbusObject_Release(inParams2);

sleep(10);

Expand All @@ -217,6 +215,8 @@ int main(int argc, char *argv[])
printf("multiRbusOpenMethodConsumer: rbus_close handle1 err: %d\n", rc1);
}
exit1:
rbusObject_Release(inParams1);
rbusObject_Release(inParams2);

printf("multiRbusOpenMethodConsumer: exit\n");
return rc2;
Expand Down

0 comments on commit 611ad5f

Please sign in to comment.