Module: Rubory
- Defined in:
- lib/factories.rb
Defined Under Namespace
Classes: CreationDsl, Factories, Factory, NoSuchFactoryException, NotSupportedException
Class Method Summary
collapse
Class Method Details
.attributes_for(name, attribute_overrides = {}) ⇒ Object
11
12
13
|
# File 'lib/factories.rb', line 11
def self.attributes_for(name, attribute_overrides = {})
factories.attributes_for(name, attribute_overrides)
end
|
.build(name, attribute_overrides = {}) ⇒ Object
8
9
10
|
# File 'lib/factories.rb', line 8
def self.build(name, attribute_overrides = {})
factories.build(name, attribute_overrides)
end
|
.clear_all ⇒ Object
20
21
22
|
# File 'lib/factories.rb', line 20
def self.clear_all
@@factories = nil
end
|
.create(name, attribute_overrides = {}) ⇒ Object
5
6
7
|
# File 'lib/factories.rb', line 5
def self.create(name, attribute_overrides = {})
factories.create(name)
end
|
.define(name, &definition) ⇒ Object
2
3
4
|
# File 'lib/factories.rb', line 2
def self.define(name, &definition)
factories.define(name, &definition)
end
|
.factories ⇒ Object
17
18
19
|
# File 'lib/factories.rb', line 17
def self.factories
@@factories ||= Factories.new
end
|
.use_default_module(default_module) ⇒ Object
14
15
16
|
# File 'lib/factories.rb', line 14
def self.use_default_module(default_module)
factories.use_default_module(default_module)
end
|