Western Canada Software Symposium
September 28 - 30, 2007 - Calgary, Alberta
Mocking Web Services
In this talk, we'll survey the web services exposed by leading websites (Google, Yahoo, Amazon, eBay) and discuss how they can be easily mocked up for testing purposes and to aid offline development. You'll see working examples of RESTful, SOAP, and JSON web services, as well as strategies for unit and functional testing your asynchronous, service-oriented architecture.
As more software engineers add unit testing to their everyday development regime, the concept of mock objects is becoming increasingly popular. Mock objects proxy more complicated objects, fulfilling their doppelganger's interface and behavior for testing purposes. Coding to interfaces instead of implementations is a best practice that applies equally well to POJOs and Web Services.
Web Services, too, are being added to our toolkit with increasing frequency. Building a true service-oriented architecture brings with it new challenges: how do you code against an external service? If that service is metered, how do you develop iteratively without using up your production budget in tests? These questions and more are answered in this talk.
About Scott Davis
Scott Davis is the founder of ThirstyHead.com, a training company that specializes in Groovy and Grails training.
Scott published one of the first public websites implemented in Grails in 2006 and has been actively working with the technology ever since. Author of the book Groovy Recipes: Greasing the Wheels of Java and two ongoing IBM developerWorks article series (Mastering Grails and in 2009, Practically Groovy), Scott writes extensively about how Groovy and Grails are the future of Java development.More About Scott »