Displaying 1 result from an estimated 1 matches for "mail_dump".
2007 Oct 07
2
Specing exit codes
...it 1
end
------------------------
init_spec.rb looks like this:
------------------------
require ''spec''
require ''systemu''
require ''init''
describe Init do
it "should exit on status code 1 without parameters"
command = "ruby mail_dump/init.rb" # not portable
status, stdout, stderr = systemu command
status.should == # what do I put here?
end
end
------------------------
I have tried a number of things, from trying to stub exit to aliasing
kernel.exit to something else and replacing it... all without joy.
The spec...