Class NotAMock::Stubber
In: lib/not_a_mock/stubber.rb
Parent: Object

The Stubber is a singleton that keeps track of all the stub methods installed in any object.

Methods

new   reset  

Included Modules

Singleton

Public Class methods

[Source]

    # File lib/not_a_mock/stubber.rb, line 10
10:     def initialize
11:       @stubbed_methods = []
12:     end

Public Instance methods

Removes all stub methods.

[Source]

    # File lib/not_a_mock/stubber.rb, line 34
34:     def reset
35:       @stubbed_methods.each do |object, method|
36:         remove_hook(object, method) 
37:       end
38:       @stubbed_methods = []
39:     end

[Validate]