class Fabricate
Public Class Methods
clear_singletons!()
click to toggle source
# File lib/roqua/core_ext/fabrication/singleton.rb, line 7 def self.clear_singletons! @singletons = {} end
singleton(name, options={}, &block)
click to toggle source
# File lib/roqua/core_ext/fabrication/singleton.rb, line 2 def self.singleton(name, options={}, &block) @singletons[name] ||= Fabricate(name, options={}, &block) return @singletons[name] end