Class: RSpec::Bash::Mocks::Doubles::ExactConditionalDouble
Instance Attribute Summary collapse
#behaviors, #call_original, #calls, #expected_call_count, #expected_calls, #subshell
Instance Method Summary
collapse
Constructor Details
Returns a new instance of ExactConditionalDouble.
8
9
10
11
12
|
# File 'lib/rspec/bash/mocks/doubles/exact_conditional_double.rb', line 8
def initialize(fullexpr)
super()
@fullexpr = fullexpr
end
|
Instance Attribute Details
#fullexpr ⇒ Object
Returns the value of attribute fullexpr.
6
7
8
|
# File 'lib/rspec/bash/mocks/doubles/exact_conditional_double.rb', line 6
def fullexpr
@fullexpr
end
|
Instance Method Details
#apply(script) ⇒ Object
14
15
16
17
18
|
# File 'lib/rspec/bash/mocks/doubles/exact_conditional_double.rb', line 14
def apply(script)
script.stub_conditional(@fullexpr,
behaviors: behaviors
)
end
|
#call_args(script) ⇒ Object
24
25
26
|
# File 'lib/rspec/bash/mocks/doubles/exact_conditional_double.rb', line 24
def call_args(script)
script.exact_conditional_calls_for(@fullexpr)
end
|
#call_count(script) ⇒ Object
20
21
22
|
# File 'lib/rspec/bash/mocks/doubles/exact_conditional_double.rb', line 20
def call_count(script)
script.exact_conditional_calls_for(@fullexpr).count
end
|
#to_s ⇒ Object
28
29
30
|
# File 'lib/rspec/bash/mocks/doubles/exact_conditional_double.rb', line 28
def to_s
@fullexpr.to_s
end
|