Sha256: 2cda84dcbab8c24f586734f31bafa21e8d8487da8e3c59b67da5d88dcc17a2a6
Contents?: true
Size: 424 Bytes
Versions: 80
Compression:
Stored size: 424 Bytes
Contents
module Mocha class Central attr_accessor :stubba_methods def initialize self.stubba_methods = [] end def stub(method) unless stubba_methods.include?(method) method.stub stubba_methods.push(method) end end def unstub_all while stubba_methods.length > 0 method = stubba_methods.pop method.unstub end end end end
Version data entries
80 entries across 80 versions & 10 rubygems