test/test_command_runner.rb in cri-2.6.1 vs test/test_command_runner.rb in cri-2.7.0
- old
+ new
@@ -1,32 +1,31 @@
# encoding: utf-8
-class Cri::CommandRunnerTestCase < Cri::TestCase
+module Cri
+ class CommandRunnerTestCase < Cri::TestCase
+ def setup
+ super
- def setup
- super
+ @options = { :vehicle => 'pig' }
+ @arguments = %w( baby_monkey )
+ @command = Cri::Command.new
+ end
- @options = { :vehicle => 'pig' }
- @arguments = %w( baby_monkey )
- @command = Cri::Command.new
- end
+ def test_initialize
+ runner = Cri::CommandRunner.new(@options, @arguments, @command)
- def test_initialize
+ assert_equal @options, runner.options
+ assert_equal @arguments, runner.arguments
+ assert_equal @command, runner.command
+ end
- runner = Cri::CommandRunner.new(@options, @arguments, @command)
+ def test_call_run
+ assert_raises(Cri::NotImplementedError) do
+ Cri::CommandRunner.new(@options, @arguments, @command).call
+ end
- assert_equal @options, runner.options
- assert_equal @arguments, runner.arguments
- assert_equal @command, runner.command
- end
-
- def test_call_run
- assert_raises(Cri::NotImplementedError) do
- Cri::CommandRunner.new(@options, @arguments, @command).call
+ assert_raises(Cri::NotImplementedError) do
+ Cri::CommandRunner.new(@options, @arguments, @command).run
+ end
end
-
- assert_raises(Cri::NotImplementedError) do
- Cri::CommandRunner.new(@options, @arguments, @command).run
- end
end
-
end