From f8012062596783e0e518e3f11d94bb2916a5f84f Mon Sep 17 00:00:00 2001 From: Naoki Mizuno Date: Tue, 8 Sep 2015 08:40:29 -0400 Subject: Fix arguments removed with option arguments See #181. --- test/parser_test.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'test') diff --git a/test/parser_test.rb b/test/parser_test.rb index 85ba7e0..bfc4f7e 100644 --- a/test/parser_test.rb +++ b/test/parser_test.rb @@ -66,5 +66,10 @@ describe Slop::Parser do @parser.parse %w(-v -- --name lee) assert_equal %w(--name lee), @parser.arguments end + + it "correctly removes the option argument" do + @parser.parse %w(lee --name lee lee) + assert_equal %w(lee lee), @parser.arguments + end end end -- cgit v1.2.1