ttilley-factory_girl 1.2.2.1 → 1.2.2.2

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -37,7 +37,7 @@ end
37
37
 
38
38
  spec = Gem::Specification.new do |s|
39
39
  s.name = %q{factory_girl}
40
- s.version = "1.2.2.1"
40
+ s.version = "1.2.2.2"
41
41
  s.summary = %q{factory_girl provides a framework and DSL for defining and
42
42
  using model instance factories.}
43
43
  s.description = %q{factory_girl provides a framework and DSL for defining and
@@ -35,10 +35,11 @@ class Factory
35
35
  module ClassMethods #:nodoc:
36
36
 
37
37
  def make(*args)
38
+ overrides = args.last.is_a?(Hash) ? args.pop : {}
39
+ name = args.first.is_a?(Symbol) ? args.shift : 'master'
40
+
38
41
  scope = self.name.underscore
39
- name = args.shift if args.first.is_a?(Symbol)
40
- name ||= 'master'
41
- overrides = args.pop || {}
42
+
42
43
  Factory.create("#{scope}[#{name}]", overrides)
43
44
  end
44
45
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ttilley-factory_girl
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.2.1
4
+ version: 1.2.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joe Ferris
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-09-02 00:00:00 -07:00
12
+ date: 2009-09-03 00:00:00 -07:00
13
13
  default_executable:
14
14
  dependencies: []
15
15
 
@@ -66,7 +66,6 @@ files:
66
66
  - spec/spec_helper.rb
67
67
  has_rdoc: false
68
68
  homepage: http://thoughtbot.com/projects/factory_girl
69
- licenses:
70
69
  post_install_message:
71
70
  rdoc_options:
72
71
  - --line-numbers
@@ -89,7 +88,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
89
88
  requirements: []
90
89
 
91
90
  rubyforge_project:
92
- rubygems_version: 1.3.5
91
+ rubygems_version: 1.2.0
93
92
  signing_key:
94
93
  specification_version: 3
95
94
  summary: factory_girl provides a framework and DSL for defining and using model instance factories.