Method: Sequel::Model.factory
- Defined in:
- lib/cutest/database/sequel_factories.rb
.factory(name = :default) ⇒ Object
Gets/sets the factory with the given name. If a block is given, uses that block to create a new factory.
81 82 83 84 |
# File 'lib/cutest/database/sequel_factories.rb', line 81 def self.factory(name=:default) factories[name] = Factory.new(Proc.new) if block_given? factories[name] end |