Capture the output of Jekyll::Commands::New when looking for an error.

This commit is contained in:
Parker Moore 2014-11-23 12:53:36 -08:00
parent 665178d210
commit 03d9396b85
1 changed files with 4 additions and 2 deletions

View File

@ -79,8 +79,10 @@ class TestNewCommand < Test::Unit::TestCase
should 'force created folder' do
capture_stdout { Jekyll::Commands::New.process(@args) }
assert_nothing_raised(SystemExit) { Jekyll::Commands::New.process(@args, '--force') }
end
assert_nothing_raised(SystemExit) do
capture_stdout {Jekyll::Commands::New.process(@args, '--force') }
end
end
end
context 'when multiple args are given' do