diff options
Diffstat (limited to 'spec/cli_spec.rb')
-rw-r--r-- | spec/cli_spec.rb | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/spec/cli_spec.rb b/spec/cli_spec.rb index 0a6c91b..eb9872e 100644 --- a/spec/cli_spec.rb +++ b/spec/cli_spec.rb @@ -2,23 +2,20 @@ require 'spec_helper' require 'oxidized/cli' describe Oxidized::CLI do - let(:asetus) { mock() } - - after { ARGV.replace @original } before { @original = ARGV } + after { ARGV.replace @original } %w[-v --version].each do |option| describe option do - before { ARGV.replace [option] } + before { ARGV.replace([option]) } it 'prints the version and exits' do Oxidized::Config.expects(:load) Oxidized.expects(:setup_logger) + File.expects(:expand_path) Kernel.expects(:exit) - proc { - Oxidized::CLI.new - }.must_output "#{Oxidized::VERSION}\n" + assert_output("#{Oxidized::VERSION}\n") { Oxidized::CLI.new } end end end |