lib/bogus/fakes/method_stringifier.rb in bogus-0.1.4 vs lib/bogus/fakes/method_stringifier.rb in bogus-0.1.5
- old
+ new
@@ -27,9 +27,10 @@
def argument_to_string(name, type, default)
case type
when :block then "&#{name}"
when :key then default ? "#{name}: #{default}" : "#{name}: #{name}"
+ when :keyreq then default ? "#{name}:" : "#{name}: #{name}"
when :opt then default ? "#{name} = #{default}" : name
when :req then name
when :rest then "*#{name}"
when :keyrest then "**#{name}"
else raise "unknown argument type: #{type}"