I am building a Ruby command-line program that communicates with a web service. I am using Cucumber and Aruba to test the program. The problem is that I need to control the data returned from the web service; the program grabs a stream of user comments, so this can change frequently as new comments are added. I tried to mock the web service using WebMock, but this didn't work, since Aruba spins the command-line program off into a separate process that is unaffected by WebMock (so it still communicated with the real web service).
How can I test the output of this program using Cucumber?
Edit: The web service returns the stream as JSON data. I've captured a snapshot of data to use for testing; in a nutshell, I'm looking for a way to substitute my static data in place of an actual call to the web service.
Or, if there's a completely different way to accomplish this goal, I'm all ears.