Skip to content

Commit

Permalink
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions spec/regression/GH-4186.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# This is not really ruby/spec worthy as it is a weird internal mistake on
# our part in checking all variables.

describe "#4186 JRuby accepts wrong method arguments when mixing positional with defaults and keywords" do
it "complains about missing required kwarg" do
def gh4186(a=1, b:); end
expect { gh4186(a: 2, b: 3) }.to raise_error(ArgumentError)
end
end

0 comments on commit 18800ed

Please sign in to comment.