spec/dircat/cli/command_diff_spec.rb in dircat-0.1.8 vs spec/dircat/cli/command_diff_spec.rb in dircat-0.1.9
- old
+ new
@@ -2,13 +2,10 @@
require File.expand_path( File.join(File.dirname(__FILE__), "..", "..", "spec_helper") )
describe CommandDiff do
it "should accept -h (help) option" do
- out = with_stdout_captured do
- args = %w{diff -h}
- CliDirCat.new.parse_and_execute(args)
- end
+ out = capture_out { CliDirCat.run %w{diff -h} }.out
out.should match /Usage:/
end
end