In doing so I always run across the issue of how to spec these
interactions, how to debug what's being passed back and forth etc...
In my rspreedly gem [1] I stub out the HTTP requests on a fairly low
level and use fixtures for the XML being passed which I generated by
using Martin's net-http-spy [2].
Other options include:
* FakeWeb [3]
* Just use the actual service
* Build a mock/simulated app to test against
* A replaying middleman/proxy like wiretapper [4]
Would anyone be interested in a talk where I look into these
issues/options and the pros and cons of the various approaches?
[1] http://github.com/rlivsey/rspreedly
[2] http://github.com/martinbtt/net-http-spy/
[3] http://fakeweb.rubyforge.org/
[4] http://github.com/joshuabates/wiretapper/
--
Richard Livsey
Minutebase - Online Meeting Minutes
http://minutebase.com
http://livsey.org
> I've written a few things recently which work against 3rd party HTTP
> API's recently.
>
> In doing so I always run across the issue of how to spec these
> interactions, how to debug what's being passed back and forth etc...
>
> In my rspreedly gem [1] I stub out the HTTP requests on a fairly low
> level and use fixtures for the XML being passed which I generated by
> using Martin's net-http-spy [2].
>
> Other options include:
>
> * FakeWeb [3]
> * Just use the actual service
> * Build a mock/simulated app to test against
> * A replaying middleman/proxy like wiretapper [4]
>
> Would anyone be interested in a talk where I look into these
> issues/options and the pros and cons of the various approaches?
+1 from me. I've used FakeWeb extensively, and run into some interesting issues - would like to see the terrain surveyed...
Matt
--
Matt Patterson | Design & Code
<ma...@reprocessed.org> | http://www.reprocessed.org/
I think this might be most interesting to me with a walk-through example; I know about FakeWeb, or at least that it exists, but I don't tend to reach for it. Maybe if I see how someone builds their tests against in with some concrete examples.
What do you think?
- James
I've not used FakeWeb myself, so figure it might be a good time to look into it!
I was thinking of maybe going through each of the options, showing
some real examples of how specs could work for each one and then a bit
of compare and contrast to see the benefits of each method?