What is a good way to test Java web service client code?
-
I have some Java web service client code (REST and JSON) using Apache HttpClient. I want to test that it is sending the correct requests. I already have unit tests that check the logic before I send it out. On top of that, I would like to test the HTTP requests itself. Unfortunately, Apache HttpClient doesn't provide a mock serverĀ which I can test. What is a good tool to use? I am using embedded Jetty insideĀ JUnit tests, but found some limitations, as I described in this question:
-
Answer:
If you are looking for mocking your REST services, https://github.com/mkotsur/restito could be a good option.
Aneesh Nair at Quora Visit the source
Related Q & A:
- What is a good way to structure mark-up generating code and avoid the example mess?Best solution by Code Review
- What is a good way to advertise enexpensively for a small business? It is handyman work?Best solution by Yahoo! Answers
- What's a good way to let a girl know you are interested in her?Best solution by Yahoo! Answers
- What is a good way to break in a snowboard?Best solution by answers.yahoo.com
- What's a good free IQ test website?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.