I like Graeme's approach for testing the API, but that's not integration testing. That's functional or possibly acceptance testing.
Rob On Oct 4, 2012, at 11:42 AM, Chris McCann wrote: > Thanks, all, I (and my QA team) appreciate the thoughtful input. > > Graeme: Your approach sounds pretty much inline with what I was envisioning, > so thanks for the suggestion. > > Cheers, > > Chris > > On Thursday, October 4, 2012 11:17:25 AM UTC-7, Graeme Worthy wrote: > May of these things are magical, and will be angry with you to do anything > outside of their designed parameters. Capybara will fight you. > > You are testing an API, you need to send it things, and test the responses. > Also, you say it's restful. > > If you'd like to use something declarative, then I'd like to suggest: Rspec > for writing your rules. > And rest-client for making your requests. > > https://github.com/archiloque/rest-client > > The requests and responses are very clean and easy to read. > Webrat and Capybara are great for testing forms and buttons, but since you're > touching an api, then you just need a clean syntax for describing your post, > get statements and inspecting their responses. > > -Graeme > On Thursday, October 4, 2012 at 10:59 AM, Robert Evans wrote: > >> Cucumber with Capybara will work in JRuby, so you should be able to use that >> and test the API. Capybara will need to be setup with selenium or >> poltergeist. >> >> >> On Oct 4, 2012, at 10:35 AM, Chris McCann <[email protected]> wrote: >> >>> In my day job I work on a large Java-based web app that uses a RESTful JSON >>> API to serve data to a JS-based front-end. Our QA folks are struggling a >>> bit with how best to do automated testing of the API. >>> >>> I've done some googling but come up empty-handed. Can anyone recommend a >>> solid integration testing framework that uses declarative (think "shoulda") >>> language for describing tests that we could use to exercise the API? >>> >>> Thanks, >>> >>> Chris >>> >>> -- >>> SD Ruby mailing list >>> [email protected] >>> http://groups.google.com/group/sdruby >> >> ========= >> Robert Evans >> Code Wranglers, Inc >> >> http://www.codewranglers.org >> http://www.github.com/revans >> http://www.linkedin/in/rrevans >> >> >> -- >> SD Ruby mailing list >> [email protected] >> http://groups.google.com/group/sdruby > > > -- > SD Ruby mailing list > [email protected] > http://groups.google.com/group/sdruby -- SD Ruby mailing list [email protected] http://groups.google.com/group/sdruby
