Parent

Files

Class Index [+]

Quicksearch

Mocha::Mock

Improvement for Mocha’s Mock: stub_everything with a default return value other than nil.

Public Instance Methods

method_missing_with_stub_default_value(symbol, *arguments, &block) click to toggle source

(Not documented)

     # File vendor/plugins/ubiquo_core/lib/ubiquo/extensions/test_case.rb, line 149
149:     def method_missing_with_stub_default_value(symbol, *arguments, &block)
150:       value = method_missing_without_stub_default_value(symbol, *arguments, &block)
151:       if !@expectations.match_allowing_invocation(symbol, *arguments) && !@expectations.match(symbol, *arguments) && @everything_stubbed
152:         @everything_stubbed_default_value
153:       else
154:         value
155:       end
156:     end
stub_default_value=(value) click to toggle source

(Not documented)

     # File vendor/plugins/ubiquo_core/lib/ubiquo/extensions/test_case.rb, line 143
143:   def stub_default_value= value
144:     @everything_stubbed_default_value = value
145:   end

Disabled; run with $DEBUG to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.