to_factory 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/Gemfile.lock CHANGED
@@ -1,14 +1,18 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- to_factory (0.0.1)
4
+ to_factory (0.0.2)
5
5
  factory_girl_rails
6
+ rails (~> 3.0)
6
7
 
7
8
  GEM
8
9
  remote: http://rubygems.org/
9
10
  remote: http://gems.github.com/
10
11
  specs:
11
12
  abstract (1.0.0)
13
+ actionmailer (3.0.10)
14
+ actionpack (= 3.0.10)
15
+ mail (~> 2.2.19)
12
16
  actionpack (3.0.10)
13
17
  activemodel (= 3.0.10)
14
18
  activesupport (= 3.0.10)
@@ -28,6 +32,9 @@ GEM
28
32
  activesupport (= 3.0.10)
29
33
  arel (~> 2.0.10)
30
34
  tzinfo (~> 0.3.23)
35
+ activeresource (3.0.10)
36
+ activemodel (= 3.0.10)
37
+ activesupport (= 3.0.10)
31
38
  activesupport (3.0.10)
32
39
  arel (2.0.10)
33
40
  builder (2.1.2)
@@ -41,11 +48,26 @@ GEM
41
48
  railties (>= 3.0.0)
42
49
  i18n (0.5.0)
43
50
  linecache (0.43)
51
+ mail (2.2.19)
52
+ activesupport (>= 2.3.6)
53
+ i18n (>= 0.4.0)
54
+ mime-types (~> 1.16)
55
+ treetop (~> 1.4.8)
56
+ mime-types (1.16)
57
+ polyglot (0.3.2)
44
58
  rack (1.2.3)
45
59
  rack-mount (0.6.14)
46
60
  rack (>= 1.0.0)
47
61
  rack-test (0.5.7)
48
62
  rack (>= 1.0)
63
+ rails (3.0.10)
64
+ actionmailer (= 3.0.10)
65
+ actionpack (= 3.0.10)
66
+ activerecord (= 3.0.10)
67
+ activeresource (= 3.0.10)
68
+ activesupport (= 3.0.10)
69
+ bundler (~> 1.0)
70
+ railties (= 3.0.10)
49
71
  railties (3.0.10)
50
72
  actionpack (= 3.0.10)
51
73
  activesupport (= 3.0.10)
@@ -70,6 +92,9 @@ GEM
70
92
  spork (0.8.5)
71
93
  sqlite3 (1.3.4)
72
94
  thor (0.14.6)
95
+ treetop (1.4.10)
96
+ polyglot
97
+ polyglot (>= 0.3.1)
73
98
  tzinfo (0.3.29)
74
99
  wirble (0.1.3)
75
100
 
@@ -32,7 +32,7 @@ module ToFactory
32
32
  end
33
33
 
34
34
  def factory
35
- out = "Factory :#{name} do |#{abbreviation}|\n"
35
+ out = "Factory.define :#{name} do |#{abbreviation}|\n"
36
36
  out << yield if block_given?
37
37
  out << "end"
38
38
  end
@@ -1,3 +1,3 @@
1
1
  module ToFactory
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
data/spec/db/test.sqlite CHANGED
Binary file
@@ -47,7 +47,7 @@ describe ToFactory::Generator do
47
47
 
48
48
  let(:user_factory_1) do
49
49
  user_factory_1 = <<-eof
50
- Factory :user do |u|
50
+ Factory.define :user do |u|
51
51
  u.email "blah@example.com"
52
52
  u.name "Tom"
53
53
  u.some_id 7
@@ -57,7 +57,7 @@ end
57
57
  end
58
58
  let(:user_factory_2) do
59
59
  user_factory_2 = <<-eof
60
- Factory :user do |u|
60
+ Factory.define :user do |u|
61
61
  u.email "james@example.com"
62
62
  u.name "James"
63
63
  u.some_id 8
@@ -111,7 +111,7 @@ end
111
111
  @generator = ToFactory::Generator.new User
112
112
  f = @generator.factory
113
113
  output = <<-eof
114
- Factory :user do |u|
114
+ Factory.define :user do |u|
115
115
  end
116
116
  eof
117
117
  f.should == output.chop
@@ -138,7 +138,7 @@ end
138
138
 
139
139
  let(:expected) do
140
140
  expected = <<-eof
141
- Factory :user do |u|
141
+ Factory.define :user do |u|
142
142
  u.email "test@example.com"
143
143
  u.name "Jeff"
144
144
  u.some_id 8
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: to_factory
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 2
10
- version: 0.0.2
9
+ - 3
10
+ version: 0.0.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Mark Burns
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-08-21 00:00:00 +01:00
18
+ date: 2011-08-22 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency