You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Glen Mazza <gl...@gmail.com> on 2013/05/13 17:23:06 UTC

Using cURL in JUnit tests?

Hi, probably a Sergey question, to be able to quickly check that newer 
versions of CXF will run on certain JAX-RS samples, I'd like to be able 
to incorporate the cURL statements here: 
http://people.apache.org/~gmazza/restexamples/jsonp within JUnit test 
cases so I can just run "mvn test" instead of needing to start the 
server and manually run the cURL statements and visually inspect the 
results.  I can't find much though about incorporating cURL with JUnit 
tests, does someone have a similar equivalent I can use that will allow 
me to run those three cURL statements listed on that page?

Thanks,
Glen


Re: Using cURL in JUnit tests?

Posted by Sergey Beryozkin <sb...@gmail.com>.
Hi Glen
On 13/05/13 16:23, Glen Mazza wrote:
> Hi, probably a Sergey question, to be able to quickly check that newer
> versions of CXF will run on certain JAX-RS samples, I'd like to be able
> to incorporate the cURL statements here:
> http://people.apache.org/~gmazza/restexamples/jsonp within JUnit test
> cases so I can just run "mvn test" instead of needing to start the
> server and manually run the cURL statements and visually inspect the
> results. I can't find much though about incorporating cURL with JUnit
> tests, does someone have a similar equivalent I can use that will allow
> me to run those three cURL statements listed on that page?
>
You may want to experiment with Java binding for curl:
http://curl.haxx.se/libcurl/java/

Thanks, Sergey

> Thanks,
> Glen
>