On Apr 3, 2011, at 8:24 AM, andyl wrote:

> I am using rspec/aruba to do integration tests of a command-line program i'm 
> writing.
> 
> I'd like to use something like FakeWeb to stub the network calls in the 
> command-line program.
> 
> But with aruba, the program under test runs in a separate process, and 
> FakeWeb won't work.
> 
> I'm thinking of adding a command-line option to my program for testing, and 
> embedding the network faking into the executable.
> 
> Alternatively, I could write a local web service that delivers fake results.
> 
> But I hate these solutions!  I'm curious if any of you have run into this 
> issue, and if anyone can recommend a better approach.
> 
> - Andy
> _______________________________________________
> rspec-users mailing list
> rspec-users@rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users

Add a second CL program that loads up the test-specific stuff and then loads 
the original program. Have Aruba call that instead.

Pat
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to