Post a Job  |   Ask a Question?   |   Already registered? login or register
narsigh charan
11/01/2017 12:03 PM

Writing Junit Test cases for JAX-RS Rest Client.

Hi, I am facing some issues while writing the test cases for JAX-RS Rest Client. In Rest there will be 2 ends one is Rest Resource(Rest Service) and Rest Client who will consume the Rest Resource. I have developed the code for Rest Client which is working fine. But I don't understand how to write the JUnit Test cases for this client code. because the output from the rest resource is the hashcode of object which will be unique and for every time when my client will make the HTTP call it will be different so so how I will write the test cases for my rest client. and for this do I need to create a different rest resource or the same rest resource will be used for testing the rest client code and one more thing suppose if I will create one different rest resource for testing the rest client then how this rest resource will be up and running for each time when i will test my rest client or do I need to keep this rest resource up and running. Please give me some idea around it as soon as possible.
Spam    1 Comments

12/01/2017 02:16:00

Languages :