ffactory_girl 4.8.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.autotest +9 -0
- data/.gitignore +9 -0
- data/.rspec +2 -0
- data/.simplecov +4 -0
- data/.travis.yml +38 -0
- data/.yardopts +5 -0
- data/Appraisals +19 -0
- data/CONTRIBUTING.md +60 -0
- data/GETTING_STARTED.md +1391 -0
- data/Gemfile +8 -0
- data/Gemfile.lock +116 -0
- data/LICENSE +19 -0
- data/NAME.md +11 -0
- data/NEWS +290 -0
- data/README.md +98 -0
- data/Rakefile +36 -0
- data/cucumber.yml +1 -0
- data/factory_girl.gemspec +36 -0
- data/gemfiles/3.2.gemfile +10 -0
- data/gemfiles/3.2.gemfile.lock +105 -0
- data/gemfiles/4.0.gemfile +10 -0
- data/gemfiles/4.0.gemfile.lock +105 -0
- data/gemfiles/4.1.gemfile +10 -0
- data/gemfiles/4.1.gemfile.lock +104 -0
- data/gemfiles/4.2.gemfile +10 -0
- data/gemfiles/4.2.gemfile.lock +104 -0
- data/gemfiles/5.0.gemfile +10 -0
- data/gemfiles/5.0.gemfile.lock +103 -0
- data/lib/factory_girl/aliases.rb +18 -0
- data/lib/factory_girl/attribute/association.rb +27 -0
- data/lib/factory_girl/attribute/dynamic.rb +24 -0
- data/lib/factory_girl/attribute/sequence.rb +16 -0
- data/lib/factory_girl/attribute/static.rb +16 -0
- data/lib/factory_girl/attribute.rb +62 -0
- data/lib/factory_girl/attribute_assigner.rb +97 -0
- data/lib/factory_girl/attribute_list.rb +67 -0
- data/lib/factory_girl/callback.rb +40 -0
- data/lib/factory_girl/callbacks_observer.rb +21 -0
- data/lib/factory_girl/configuration.rb +37 -0
- data/lib/factory_girl/declaration/association.rb +28 -0
- data/lib/factory_girl/declaration/dynamic.rb +26 -0
- data/lib/factory_girl/declaration/implicit.rb +33 -0
- data/lib/factory_girl/declaration/static.rb +26 -0
- data/lib/factory_girl/declaration.rb +23 -0
- data/lib/factory_girl/declaration_list.rb +49 -0
- data/lib/factory_girl/decorator/attribute_hash.rb +16 -0
- data/lib/factory_girl/decorator/class_key_hash.rb +28 -0
- data/lib/factory_girl/decorator/disallows_duplicates_registry.rb +13 -0
- data/lib/factory_girl/decorator/invocation_tracker.rb +19 -0
- data/lib/factory_girl/decorator/new_constructor.rb +12 -0
- data/lib/factory_girl/decorator.rb +21 -0
- data/lib/factory_girl/definition.rb +136 -0
- data/lib/factory_girl/definition_hierarchy.rb +48 -0
- data/lib/factory_girl/definition_proxy.rb +174 -0
- data/lib/factory_girl/errors.rb +25 -0
- data/lib/factory_girl/evaluation.rb +27 -0
- data/lib/factory_girl/evaluator.rb +82 -0
- data/lib/factory_girl/evaluator_class_definer.rb +20 -0
- data/lib/factory_girl/factory.rb +163 -0
- data/lib/factory_girl/factory_runner.rb +33 -0
- data/lib/factory_girl/find_definitions.rb +25 -0
- data/lib/factory_girl/linter.rb +97 -0
- data/lib/factory_girl/null_factory.rb +18 -0
- data/lib/factory_girl/null_object.rb +24 -0
- data/lib/factory_girl/registry.rb +38 -0
- data/lib/factory_girl/reload.rb +8 -0
- data/lib/factory_girl/sequence.rb +62 -0
- data/lib/factory_girl/strategy/attributes_for.rb +13 -0
- data/lib/factory_girl/strategy/build.rb +15 -0
- data/lib/factory_girl/strategy/create.rb +18 -0
- data/lib/factory_girl/strategy/null.rb +11 -0
- data/lib/factory_girl/strategy/stub.rb +111 -0
- data/lib/factory_girl/strategy_calculator.rb +26 -0
- data/lib/factory_girl/strategy_syntax_method_registrar.rb +54 -0
- data/lib/factory_girl/syntax/default.rb +76 -0
- data/lib/factory_girl/syntax/methods.rb +111 -0
- data/lib/factory_girl/syntax.rb +7 -0
- data/lib/factory_girl/syntax_runner.rb +6 -0
- data/lib/factory_girl/trait.rb +30 -0
- data/lib/factory_girl/version.rb +3 -0
- data/lib/factory_girl.rb +156 -0
- metadata +271 -0
@@ -0,0 +1,111 @@
|
|
1
|
+
module FactoryGirl
|
2
|
+
module Syntax
|
3
|
+
## This module is a container for all strategy methods provided by
|
4
|
+
## FactoryGirl. This includes all the default strategies provided ({Methods#build},
|
5
|
+
## {Methods#create}, {Methods#build_stubbed}, and {Methods#attributes_for}), as well as
|
6
|
+
## the complementary *_list methods.
|
7
|
+
## @example singular factory execution
|
8
|
+
## # basic use case
|
9
|
+
## build(:completed_order)
|
10
|
+
##
|
11
|
+
## # factory yielding its result to a block
|
12
|
+
## create(:post) do |post|
|
13
|
+
## create(:comment, post: post)
|
14
|
+
## end
|
15
|
+
##
|
16
|
+
## # factory with attribute override
|
17
|
+
## attributes_for(:post, title: "I love Ruby!")
|
18
|
+
##
|
19
|
+
## # factory with traits and attribute override
|
20
|
+
## build_stubbed(:user, :admin, :male, name: "John Doe")
|
21
|
+
##
|
22
|
+
## @example multiple factory execution
|
23
|
+
## # basic use case
|
24
|
+
## build_list(:completed_order, 2)
|
25
|
+
## create_list(:completed_order, 2)
|
26
|
+
##
|
27
|
+
## # factory with attribute override
|
28
|
+
## attributes_for_list(:post, 4, title: "I love Ruby!")
|
29
|
+
##
|
30
|
+
## # factory with traits and attribute override
|
31
|
+
## build_stubbed_list(:user, 15, :admin, :male, name: "John Doe")
|
32
|
+
module Methods
|
33
|
+
# @!parse FactoryGirl.register_default_strategies
|
34
|
+
# @!method build(name, *traits_and_overrides, &block)
|
35
|
+
# (see #strategy_method)
|
36
|
+
# Builds a registered factory by name.
|
37
|
+
# @return [Object] instantiated object defined by the factory
|
38
|
+
|
39
|
+
# @!method create(name, *traits_and_overrides, &block)
|
40
|
+
# (see #strategy_method)
|
41
|
+
# Creates a registered factory by name.
|
42
|
+
# @return [Object] instantiated object defined by the factory
|
43
|
+
|
44
|
+
# @!method build_stubbed(name, *traits_and_overrides, &block)
|
45
|
+
# (see #strategy_method)
|
46
|
+
# Builds a stubbed registered factory by name.
|
47
|
+
# @return [Object] instantiated object defined by the factory
|
48
|
+
|
49
|
+
# @!method attributes_for(name, *traits_and_overrides, &block)
|
50
|
+
# (see #strategy_method)
|
51
|
+
# Generates a hash of attributes for a registered factory by name.
|
52
|
+
# @return [Hash] hash of attributes for the factory
|
53
|
+
|
54
|
+
# @!method build_list(name, amount, *traits_and_overrides)
|
55
|
+
# (see #strategy_method_list)
|
56
|
+
# @return [Array] array of built objects defined by the factory
|
57
|
+
|
58
|
+
# @!method create_list(name, amount, *traits_and_overrides)
|
59
|
+
# (see #strategy_method_list)
|
60
|
+
# @return [Array] array of created objects defined by the factory
|
61
|
+
|
62
|
+
# @!method build_stubbed_list(name, amount, *traits_and_overrides)
|
63
|
+
# (see #strategy_method_list)
|
64
|
+
# @return [Array] array of stubbed objects defined by the factory
|
65
|
+
|
66
|
+
# @!method attributes_for_list(name, amount, *traits_and_overrides)
|
67
|
+
# (see #strategy_method_list)
|
68
|
+
# @return [Array<Hash>] array of attribute hashes for the factory
|
69
|
+
|
70
|
+
# @!method strategy_method
|
71
|
+
# @!visibility private
|
72
|
+
# @param [Symbol] name the name of the factory to build
|
73
|
+
# @param [Array<Symbol, Symbol, Hash>] traits_and_overrides splat args traits and a hash of overrides
|
74
|
+
# @param [Proc] block block to be executed
|
75
|
+
|
76
|
+
# @!method strategy_method_list
|
77
|
+
# @!visibility private
|
78
|
+
# @param [Symbol] name the name of the factory to execute
|
79
|
+
# @param [Integer] amount the number of instances to execute
|
80
|
+
# @param [Array<Symbol, Symbol, Hash>] traits_and_overrides splat args traits and a hash of overrides
|
81
|
+
|
82
|
+
# Generates and returns the next value in a sequence.
|
83
|
+
#
|
84
|
+
# Arguments:
|
85
|
+
# name: (Symbol)
|
86
|
+
# The name of the sequence that a value should be generated for.
|
87
|
+
#
|
88
|
+
# Returns:
|
89
|
+
# The next value in the sequence. (Object)
|
90
|
+
def generate(name)
|
91
|
+
FactoryGirl.sequence_by_name(name).next
|
92
|
+
end
|
93
|
+
|
94
|
+
# Generates and returns the list of values in a sequence.
|
95
|
+
#
|
96
|
+
# Arguments:
|
97
|
+
# name: (Symbol)
|
98
|
+
# The name of the sequence that a value should be generated for.
|
99
|
+
# count: (Fixnum)
|
100
|
+
# Count of values
|
101
|
+
#
|
102
|
+
# Returns:
|
103
|
+
# The next value in the sequence. (Object)
|
104
|
+
def generate_list(name, count)
|
105
|
+
(1..count).map do
|
106
|
+
FactoryGirl.sequence_by_name(name).next
|
107
|
+
end
|
108
|
+
end
|
109
|
+
end
|
110
|
+
end
|
111
|
+
end
|
@@ -0,0 +1,30 @@
|
|
1
|
+
module FactoryGirl
|
2
|
+
# @api private
|
3
|
+
class Trait
|
4
|
+
attr_reader :name, :definition
|
5
|
+
|
6
|
+
def initialize(name, &block)
|
7
|
+
@name = name
|
8
|
+
@block = block
|
9
|
+
@definition = Definition.new(@name)
|
10
|
+
|
11
|
+
proxy = FactoryGirl::DefinitionProxy.new(@definition)
|
12
|
+
proxy.instance_eval(&@block) if block_given?
|
13
|
+
end
|
14
|
+
|
15
|
+
delegate :add_callback, :declare_attribute, :to_create, :define_trait, :constructor,
|
16
|
+
:callbacks, :attributes, to: :@definition
|
17
|
+
|
18
|
+
def names
|
19
|
+
[@name]
|
20
|
+
end
|
21
|
+
|
22
|
+
def ==(other)
|
23
|
+
name == other.name &&
|
24
|
+
block == other.block
|
25
|
+
end
|
26
|
+
|
27
|
+
protected
|
28
|
+
attr_reader :block
|
29
|
+
end
|
30
|
+
end
|
data/lib/factory_girl.rb
ADDED
@@ -0,0 +1,156 @@
|
|
1
|
+
require 'set'
|
2
|
+
require 'active_support/core_ext/module/delegation'
|
3
|
+
require 'active_support/deprecation'
|
4
|
+
require 'active_support/notifications'
|
5
|
+
|
6
|
+
require 'factory_girl/definition_hierarchy'
|
7
|
+
require 'factory_girl/configuration'
|
8
|
+
require 'factory_girl/errors'
|
9
|
+
require 'factory_girl/factory_runner'
|
10
|
+
require 'factory_girl/strategy_syntax_method_registrar'
|
11
|
+
require 'factory_girl/strategy_calculator'
|
12
|
+
require 'factory_girl/strategy/build'
|
13
|
+
require 'factory_girl/strategy/create'
|
14
|
+
require 'factory_girl/strategy/attributes_for'
|
15
|
+
require 'factory_girl/strategy/stub'
|
16
|
+
require 'factory_girl/strategy/null'
|
17
|
+
require 'factory_girl/registry'
|
18
|
+
require 'factory_girl/null_factory'
|
19
|
+
require 'factory_girl/null_object'
|
20
|
+
require 'factory_girl/evaluation'
|
21
|
+
require 'factory_girl/factory'
|
22
|
+
require 'factory_girl/attribute_assigner'
|
23
|
+
require 'factory_girl/evaluator'
|
24
|
+
require 'factory_girl/evaluator_class_definer'
|
25
|
+
require 'factory_girl/attribute'
|
26
|
+
require 'factory_girl/callback'
|
27
|
+
require 'factory_girl/callbacks_observer'
|
28
|
+
require 'factory_girl/declaration_list'
|
29
|
+
require 'factory_girl/declaration'
|
30
|
+
require 'factory_girl/sequence'
|
31
|
+
require 'factory_girl/attribute_list'
|
32
|
+
require 'factory_girl/trait'
|
33
|
+
require 'factory_girl/aliases'
|
34
|
+
require 'factory_girl/definition'
|
35
|
+
require 'factory_girl/definition_proxy'
|
36
|
+
require 'factory_girl/syntax'
|
37
|
+
require 'factory_girl/syntax_runner'
|
38
|
+
require 'factory_girl/find_definitions'
|
39
|
+
require 'factory_girl/reload'
|
40
|
+
require 'factory_girl/decorator'
|
41
|
+
require 'factory_girl/decorator/attribute_hash'
|
42
|
+
require 'factory_girl/decorator/class_key_hash'
|
43
|
+
require 'factory_girl/decorator/disallows_duplicates_registry'
|
44
|
+
require 'factory_girl/decorator/invocation_tracker'
|
45
|
+
require 'factory_girl/decorator/new_constructor'
|
46
|
+
require 'factory_girl/linter'
|
47
|
+
require 'factory_girl/version'
|
48
|
+
|
49
|
+
module FactoryGirl
|
50
|
+
def self.configuration
|
51
|
+
@configuration ||= Configuration.new
|
52
|
+
end
|
53
|
+
|
54
|
+
def self.reset_configuration
|
55
|
+
@configuration = nil
|
56
|
+
end
|
57
|
+
|
58
|
+
# Look for errors in factories and (optionally) their traits.
|
59
|
+
# Parameters:
|
60
|
+
# factories - which factories to lint; omit for all factories
|
61
|
+
# options:
|
62
|
+
# traits: true - to lint traits as well as factories
|
63
|
+
# strategy: :create - to specify the strategy for linting
|
64
|
+
def self.lint(*args)
|
65
|
+
options = args.extract_options!
|
66
|
+
factories_to_lint = args[0] || FactoryGirl.factories
|
67
|
+
linting_strategy = options[:traits] ? :factory_and_traits : :factory
|
68
|
+
factory_strategy = options[:strategy] || :create
|
69
|
+
Linter.new(factories_to_lint, linting_strategy, factory_strategy).lint!
|
70
|
+
end
|
71
|
+
|
72
|
+
class << self
|
73
|
+
delegate :factories,
|
74
|
+
:sequences,
|
75
|
+
:traits,
|
76
|
+
:callbacks,
|
77
|
+
:strategies,
|
78
|
+
:callback_names,
|
79
|
+
:to_create,
|
80
|
+
:skip_create,
|
81
|
+
:initialize_with,
|
82
|
+
:constructor,
|
83
|
+
:duplicate_attribute_assignment_from_initialize_with,
|
84
|
+
:duplicate_attribute_assignment_from_initialize_with=,
|
85
|
+
:allow_class_lookup,
|
86
|
+
:allow_class_lookup=,
|
87
|
+
:use_parent_strategy,
|
88
|
+
:use_parent_strategy=,
|
89
|
+
to: :configuration
|
90
|
+
end
|
91
|
+
|
92
|
+
def self.register_factory(factory)
|
93
|
+
factory.names.each do |name|
|
94
|
+
factories.register(name, factory)
|
95
|
+
end
|
96
|
+
factory
|
97
|
+
end
|
98
|
+
|
99
|
+
def self.factory_by_name(name)
|
100
|
+
factories.find(name)
|
101
|
+
end
|
102
|
+
|
103
|
+
def self.register_sequence(sequence)
|
104
|
+
sequence.names.each do |name|
|
105
|
+
sequences.register(name, sequence)
|
106
|
+
end
|
107
|
+
sequence
|
108
|
+
end
|
109
|
+
|
110
|
+
def self.sequence_by_name(name)
|
111
|
+
sequences.find(name)
|
112
|
+
end
|
113
|
+
|
114
|
+
def self.register_trait(trait)
|
115
|
+
trait.names.each do |name|
|
116
|
+
traits.register(name, trait)
|
117
|
+
end
|
118
|
+
trait
|
119
|
+
end
|
120
|
+
|
121
|
+
def self.trait_by_name(name)
|
122
|
+
traits.find(name)
|
123
|
+
end
|
124
|
+
|
125
|
+
def self.register_strategy(strategy_name, strategy_class)
|
126
|
+
strategies.register(strategy_name, strategy_class)
|
127
|
+
StrategySyntaxMethodRegistrar.new(strategy_name).define_strategy_methods
|
128
|
+
end
|
129
|
+
|
130
|
+
def self.strategy_by_name(name)
|
131
|
+
strategies.find(name)
|
132
|
+
end
|
133
|
+
|
134
|
+
def self.register_default_strategies
|
135
|
+
register_strategy(:build, FactoryGirl::Strategy::Build)
|
136
|
+
register_strategy(:create, FactoryGirl::Strategy::Create)
|
137
|
+
register_strategy(:attributes_for, FactoryGirl::Strategy::AttributesFor)
|
138
|
+
register_strategy(:build_stubbed, FactoryGirl::Strategy::Stub)
|
139
|
+
register_strategy(:null, FactoryGirl::Strategy::Null)
|
140
|
+
end
|
141
|
+
|
142
|
+
def self.register_default_callbacks
|
143
|
+
register_callback(:after_build)
|
144
|
+
register_callback(:after_create)
|
145
|
+
register_callback(:after_stub)
|
146
|
+
register_callback(:before_create)
|
147
|
+
end
|
148
|
+
|
149
|
+
def self.register_callback(name)
|
150
|
+
name = name.to_sym
|
151
|
+
callback_names << name
|
152
|
+
end
|
153
|
+
end
|
154
|
+
|
155
|
+
FactoryGirl.register_default_strategies
|
156
|
+
FactoryGirl.register_default_callbacks
|
metadata
ADDED
@@ -0,0 +1,271 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: ffactory_girl
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 4.8.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Josh Clayton
|
8
|
+
- Joe Ferris
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2017-10-22 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: activesupport
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
requirements:
|
18
|
+
- - ">="
|
19
|
+
- !ruby/object:Gem::Version
|
20
|
+
version: 3.0.0
|
21
|
+
type: :runtime
|
22
|
+
prerelease: false
|
23
|
+
version_requirements: !ruby/object:Gem::Requirement
|
24
|
+
requirements:
|
25
|
+
- - ">="
|
26
|
+
- !ruby/object:Gem::Version
|
27
|
+
version: 3.0.0
|
28
|
+
- !ruby/object:Gem::Dependency
|
29
|
+
name: rspec
|
30
|
+
requirement: !ruby/object:Gem::Requirement
|
31
|
+
requirements:
|
32
|
+
- - "~>"
|
33
|
+
- !ruby/object:Gem::Version
|
34
|
+
version: '3.0'
|
35
|
+
type: :development
|
36
|
+
prerelease: false
|
37
|
+
version_requirements: !ruby/object:Gem::Requirement
|
38
|
+
requirements:
|
39
|
+
- - "~>"
|
40
|
+
- !ruby/object:Gem::Version
|
41
|
+
version: '3.0'
|
42
|
+
- !ruby/object:Gem::Dependency
|
43
|
+
name: rspec-its
|
44
|
+
requirement: !ruby/object:Gem::Requirement
|
45
|
+
requirements:
|
46
|
+
- - "~>"
|
47
|
+
- !ruby/object:Gem::Version
|
48
|
+
version: '1.0'
|
49
|
+
type: :development
|
50
|
+
prerelease: false
|
51
|
+
version_requirements: !ruby/object:Gem::Requirement
|
52
|
+
requirements:
|
53
|
+
- - "~>"
|
54
|
+
- !ruby/object:Gem::Version
|
55
|
+
version: '1.0'
|
56
|
+
- !ruby/object:Gem::Dependency
|
57
|
+
name: cucumber
|
58
|
+
requirement: !ruby/object:Gem::Requirement
|
59
|
+
requirements:
|
60
|
+
- - "~>"
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: 1.3.15
|
63
|
+
type: :development
|
64
|
+
prerelease: false
|
65
|
+
version_requirements: !ruby/object:Gem::Requirement
|
66
|
+
requirements:
|
67
|
+
- - "~>"
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: 1.3.15
|
70
|
+
- !ruby/object:Gem::Dependency
|
71
|
+
name: timecop
|
72
|
+
requirement: !ruby/object:Gem::Requirement
|
73
|
+
requirements:
|
74
|
+
- - ">="
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: '0'
|
77
|
+
type: :development
|
78
|
+
prerelease: false
|
79
|
+
version_requirements: !ruby/object:Gem::Requirement
|
80
|
+
requirements:
|
81
|
+
- - ">="
|
82
|
+
- !ruby/object:Gem::Version
|
83
|
+
version: '0'
|
84
|
+
- !ruby/object:Gem::Dependency
|
85
|
+
name: simplecov
|
86
|
+
requirement: !ruby/object:Gem::Requirement
|
87
|
+
requirements:
|
88
|
+
- - ">="
|
89
|
+
- !ruby/object:Gem::Version
|
90
|
+
version: '0'
|
91
|
+
type: :development
|
92
|
+
prerelease: false
|
93
|
+
version_requirements: !ruby/object:Gem::Requirement
|
94
|
+
requirements:
|
95
|
+
- - ">="
|
96
|
+
- !ruby/object:Gem::Version
|
97
|
+
version: '0'
|
98
|
+
- !ruby/object:Gem::Dependency
|
99
|
+
name: aruba
|
100
|
+
requirement: !ruby/object:Gem::Requirement
|
101
|
+
requirements:
|
102
|
+
- - ">="
|
103
|
+
- !ruby/object:Gem::Version
|
104
|
+
version: '0'
|
105
|
+
type: :development
|
106
|
+
prerelease: false
|
107
|
+
version_requirements: !ruby/object:Gem::Requirement
|
108
|
+
requirements:
|
109
|
+
- - ">="
|
110
|
+
- !ruby/object:Gem::Version
|
111
|
+
version: '0'
|
112
|
+
- !ruby/object:Gem::Dependency
|
113
|
+
name: appraisal
|
114
|
+
requirement: !ruby/object:Gem::Requirement
|
115
|
+
requirements:
|
116
|
+
- - "~>"
|
117
|
+
- !ruby/object:Gem::Version
|
118
|
+
version: 2.1.0
|
119
|
+
type: :development
|
120
|
+
prerelease: false
|
121
|
+
version_requirements: !ruby/object:Gem::Requirement
|
122
|
+
requirements:
|
123
|
+
- - "~>"
|
124
|
+
- !ruby/object:Gem::Version
|
125
|
+
version: 2.1.0
|
126
|
+
- !ruby/object:Gem::Dependency
|
127
|
+
name: activerecord
|
128
|
+
requirement: !ruby/object:Gem::Requirement
|
129
|
+
requirements:
|
130
|
+
- - ">="
|
131
|
+
- !ruby/object:Gem::Version
|
132
|
+
version: 3.0.0
|
133
|
+
type: :development
|
134
|
+
prerelease: false
|
135
|
+
version_requirements: !ruby/object:Gem::Requirement
|
136
|
+
requirements:
|
137
|
+
- - ">="
|
138
|
+
- !ruby/object:Gem::Version
|
139
|
+
version: 3.0.0
|
140
|
+
- !ruby/object:Gem::Dependency
|
141
|
+
name: yard
|
142
|
+
requirement: !ruby/object:Gem::Requirement
|
143
|
+
requirements:
|
144
|
+
- - ">="
|
145
|
+
- !ruby/object:Gem::Version
|
146
|
+
version: '0'
|
147
|
+
type: :development
|
148
|
+
prerelease: false
|
149
|
+
version_requirements: !ruby/object:Gem::Requirement
|
150
|
+
requirements:
|
151
|
+
- - ">="
|
152
|
+
- !ruby/object:Gem::Version
|
153
|
+
version: '0'
|
154
|
+
description: |-
|
155
|
+
ffactory_girl provides a framework and DSL for defining and
|
156
|
+
using factories - less error-prone, more explicit, and
|
157
|
+
all-around easier to work with than fixtures.
|
158
|
+
email:
|
159
|
+
- jclayton@thoughtbot.com
|
160
|
+
- jferris@thoughtbot.com
|
161
|
+
executables: []
|
162
|
+
extensions: []
|
163
|
+
extra_rdoc_files: []
|
164
|
+
files:
|
165
|
+
- ".autotest"
|
166
|
+
- ".gitignore"
|
167
|
+
- ".rspec"
|
168
|
+
- ".simplecov"
|
169
|
+
- ".travis.yml"
|
170
|
+
- ".yardopts"
|
171
|
+
- Appraisals
|
172
|
+
- CONTRIBUTING.md
|
173
|
+
- GETTING_STARTED.md
|
174
|
+
- Gemfile
|
175
|
+
- Gemfile.lock
|
176
|
+
- LICENSE
|
177
|
+
- NAME.md
|
178
|
+
- NEWS
|
179
|
+
- README.md
|
180
|
+
- Rakefile
|
181
|
+
- cucumber.yml
|
182
|
+
- factory_girl.gemspec
|
183
|
+
- gemfiles/3.2.gemfile
|
184
|
+
- gemfiles/3.2.gemfile.lock
|
185
|
+
- gemfiles/4.0.gemfile
|
186
|
+
- gemfiles/4.0.gemfile.lock
|
187
|
+
- gemfiles/4.1.gemfile
|
188
|
+
- gemfiles/4.1.gemfile.lock
|
189
|
+
- gemfiles/4.2.gemfile
|
190
|
+
- gemfiles/4.2.gemfile.lock
|
191
|
+
- gemfiles/5.0.gemfile
|
192
|
+
- gemfiles/5.0.gemfile.lock
|
193
|
+
- lib/factory_girl.rb
|
194
|
+
- lib/factory_girl/aliases.rb
|
195
|
+
- lib/factory_girl/attribute.rb
|
196
|
+
- lib/factory_girl/attribute/association.rb
|
197
|
+
- lib/factory_girl/attribute/dynamic.rb
|
198
|
+
- lib/factory_girl/attribute/sequence.rb
|
199
|
+
- lib/factory_girl/attribute/static.rb
|
200
|
+
- lib/factory_girl/attribute_assigner.rb
|
201
|
+
- lib/factory_girl/attribute_list.rb
|
202
|
+
- lib/factory_girl/callback.rb
|
203
|
+
- lib/factory_girl/callbacks_observer.rb
|
204
|
+
- lib/factory_girl/configuration.rb
|
205
|
+
- lib/factory_girl/declaration.rb
|
206
|
+
- lib/factory_girl/declaration/association.rb
|
207
|
+
- lib/factory_girl/declaration/dynamic.rb
|
208
|
+
- lib/factory_girl/declaration/implicit.rb
|
209
|
+
- lib/factory_girl/declaration/static.rb
|
210
|
+
- lib/factory_girl/declaration_list.rb
|
211
|
+
- lib/factory_girl/decorator.rb
|
212
|
+
- lib/factory_girl/decorator/attribute_hash.rb
|
213
|
+
- lib/factory_girl/decorator/class_key_hash.rb
|
214
|
+
- lib/factory_girl/decorator/disallows_duplicates_registry.rb
|
215
|
+
- lib/factory_girl/decorator/invocation_tracker.rb
|
216
|
+
- lib/factory_girl/decorator/new_constructor.rb
|
217
|
+
- lib/factory_girl/definition.rb
|
218
|
+
- lib/factory_girl/definition_hierarchy.rb
|
219
|
+
- lib/factory_girl/definition_proxy.rb
|
220
|
+
- lib/factory_girl/errors.rb
|
221
|
+
- lib/factory_girl/evaluation.rb
|
222
|
+
- lib/factory_girl/evaluator.rb
|
223
|
+
- lib/factory_girl/evaluator_class_definer.rb
|
224
|
+
- lib/factory_girl/factory.rb
|
225
|
+
- lib/factory_girl/factory_runner.rb
|
226
|
+
- lib/factory_girl/find_definitions.rb
|
227
|
+
- lib/factory_girl/linter.rb
|
228
|
+
- lib/factory_girl/null_factory.rb
|
229
|
+
- lib/factory_girl/null_object.rb
|
230
|
+
- lib/factory_girl/registry.rb
|
231
|
+
- lib/factory_girl/reload.rb
|
232
|
+
- lib/factory_girl/sequence.rb
|
233
|
+
- lib/factory_girl/strategy/attributes_for.rb
|
234
|
+
- lib/factory_girl/strategy/build.rb
|
235
|
+
- lib/factory_girl/strategy/create.rb
|
236
|
+
- lib/factory_girl/strategy/null.rb
|
237
|
+
- lib/factory_girl/strategy/stub.rb
|
238
|
+
- lib/factory_girl/strategy_calculator.rb
|
239
|
+
- lib/factory_girl/strategy_syntax_method_registrar.rb
|
240
|
+
- lib/factory_girl/syntax.rb
|
241
|
+
- lib/factory_girl/syntax/default.rb
|
242
|
+
- lib/factory_girl/syntax/methods.rb
|
243
|
+
- lib/factory_girl/syntax_runner.rb
|
244
|
+
- lib/factory_girl/trait.rb
|
245
|
+
- lib/factory_girl/version.rb
|
246
|
+
homepage: https://github.com/kalys/ffactory_girl
|
247
|
+
licenses:
|
248
|
+
- MIT
|
249
|
+
metadata: {}
|
250
|
+
post_install_message:
|
251
|
+
rdoc_options: []
|
252
|
+
require_paths:
|
253
|
+
- lib
|
254
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
255
|
+
requirements:
|
256
|
+
- - ">="
|
257
|
+
- !ruby/object:Gem::Version
|
258
|
+
version: 1.9.2
|
259
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
260
|
+
requirements:
|
261
|
+
- - ">="
|
262
|
+
- !ruby/object:Gem::Version
|
263
|
+
version: '0'
|
264
|
+
requirements: []
|
265
|
+
rubyforge_project:
|
266
|
+
rubygems_version: 2.4.8
|
267
|
+
signing_key:
|
268
|
+
specification_version: 4
|
269
|
+
summary: ffactory_girl provides a framework and DSL for defining and using model instance
|
270
|
+
factories.
|
271
|
+
test_files: []
|