Class: RSpec::Mocks::BlockSignature Private
- Defined in:
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Deals with the slightly different semantics of block arguments. For methods, arguments are required unless a default value is provided. For blocks, arguments are optional, even if no default value is provided.
However, we want to treat block args as required since you virtually always
want to pass a value for each received argument and our
treated block args as required for many years.
Instance Method Summary (collapse)
- - (Object) classify_parameters private
Instance Method Details
- (Object) classify_parameters
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
134 135 136 137
# File 'lib/rspec/mocks/method_signature_verifier.rb', line 134 def classify_parameters super @min_non_kw_args = @max_non_kw_args unless @max_non_kw_args == INFINITY end