diff options
Diffstat (limited to 'spec/unit/application')
| -rwxr-xr-x | spec/unit/application/string_base_spec.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/unit/application/string_base_spec.rb b/spec/unit/application/string_base_spec.rb index 5cfb8352a..71e67283d 100755 --- a/spec/unit/application/string_base_spec.rb +++ b/spec/unit/application/string_base_spec.rb @@ -112,6 +112,12 @@ describe Puppet::Application::StringBase do app.action.name.should == :foo app.options.should == { :mandatory => "--bar" } end + + it "should not skip when --foo=bar is given" do + app.command_line.stubs(:args).returns %w{--mandatory=bar --bar foo} + expect { app.preinit }. + should raise_error ArgumentError, /Unknown option "--bar"/ + end end end |
