File tree 1 file changed +26
-0
lines changed
features/builtin_contracts
1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -48,3 +48,29 @@ Feature: KeywordArgs when used with optional positional arguments
48
48
["c", "d"]
49
49
output
50
50
"""
51
+
52
+ Scenario : Accepts arguments when only require arguments & optional keyword arguments filled and valid
53
+ Given a file named "accepts_all_filled_valid_args.rb" with:
54
+ """ruby
55
+ require "./keyword_args_with_optional_positional_args_usage"
56
+ puts Example.new.foo(:output, b: 'd')
57
+ """
58
+ When I run `ruby accepts_all_filled_valid_args.rb`
59
+ Then output should contain:
60
+ """
61
+ ["a", "d"]
62
+ output
63
+ """
64
+
65
+ Scenario : Accepts arguments when only require arguments & optional positional arguments filled and valid
66
+ Given a file named "accepts_all_filled_valid_args.rb" with:
67
+ """ruby
68
+ require "./keyword_args_with_optional_positional_args_usage"
69
+ puts Example.new.foo(:output, 'c')
70
+ """
71
+ When I run `ruby accepts_all_filled_valid_args.rb`
72
+ Then output should contain:
73
+ """
74
+ ["c", "b"]
75
+ output
76
+ """
You can’t perform that action at this time.
0 commit comments