Sha256: 94fd34e5493ce38bf1f2584bdca333e988e94e372a066a0f7f799446899366a3
Contents?: true
Size: 593 Bytes
Versions: 18
Compression:
Stored size: 593 Bytes
Contents
require 'spec_helper' require 'system_builder/cli' describe SystemBuilder::CLI, "execute" do class ExitException < Exception; end; before(:each) do SystemBuilder::CLI.stub!(:exit).and_raise(ExitException) end def system_builder(*arguments) @stdout_io = StringIO.new begin SystemBuilder::CLI.execute(@stdout_io, arguments.flatten) rescue ExitException end @stdout_io.rewind @stdout = @stdout_io.read end it "should print default output" do system_builder "--help" @stdout.should =~ /Usage: .* \[options\] image command/ end end
Version data entries
18 entries across 18 versions & 1 rubygems