lib/bolt_spec/plans/action_stubs/task_stub.rb
# Restricts the stub to only match invocations with certain parameters.
# All parameters must match exactly.
Restricts the stub to only match invocations with certain parameters.
All parameters must match exactly.
Restricts the stub to only match invocations with certain parameters . All parameters must match exactly .
def with_params(params)
        @invocation[:params] = params
        @invocation[:arguments] = params.reject { |k, _v| k.start_with?('_') }
        @invocation[:options] = params.select { |k, _v| k.start_with?('_') }
                                      .transform_keys { |k| k.sub(/^_/, '').to_sym }
        self
      end
def with_params ( params ) @invocation [ :params ] = params @invocation [ :arguments ] = params . reject { | k , _v | k . start_with? ( '_' ) } @invocation [ :options ] = params . select { | k , _v | k . start_with? ( '_' ) } . transform_keys { | k | k . sub ( / ^_ / , '' ) . to_sym } self end
Restricts the stub to only match invocations with certain parameters.
Restricts the stub to only match invocations with certain parameters .
params
<not_specific>