• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Junit testing approach for webservices(SOAP) with out hitting server ?

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

How do we do Junit/unit testing of web services(SOAP/REST) without starting actual container
and these junit tests are the part of maven integration.

Any suggestions pleaseeee....?

Thanks & Regards
Jagadeesh G

 
Ranch Hand
Posts: 2198
1
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
Have you considered starting an embedded Jetty or Tomcat instance?
I have used Metro in Tomcat and it works fine.
There is also Arquillian from JBoss which is supposed to enable testing in an embedded container:
http://www.jboss.org/arquillian
It does seem slightly unfinished, as of today, so I have only waited and observed so far.
Best wishes!
 
jagadeeshnaidu guthikonda
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ivan Krizsan wrote:Hi!
Have you considered starting an embedded Jetty or Tomcat instance?
I have used Metro in Tomcat and it works fine.
There is also Arquillian from JBoss which is supposed to enable testing in an embedded container:
http://www.jboss.org/arquillian
It does seem slightly unfinished, as of today, so I have only waited and observed so far.
Best wishes!



Hi Ivan Krizsan ,
please share the links related to embedded jetty or tomcat inistance???


Thanks
Jagadeesh G
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
Embedded Jetty: http://docs.codehaus.org/display/JETTY/Embedding+Jetty
Embedded Tomcat: http://tomcat.apache.org/tomcat-6.0-doc/api/org/apache/catalina/startup/Embedded.html
Best wishes!
 
jagadeeshnaidu guthikonda
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
please post if you have any articles or links related to SOAP webservices junit testing without hitting actual server(we can use any mock server).


Thanks
Jagadeesh
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ah, I almost forgot!
There is the javax.xml.ws.Endpoint in the Java SE 6 API, which can help you to publish a standalone service.
This is very useful for unit testing web services.
Best wishes!
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic