nifty-generators 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG CHANGED
@@ -1,3 +1,11 @@
1
+ 0.2.4 (May 5th, 2009)
2
+
3
+ * using root_url when no index action in nifty_scaffold
4
+
5
+ * making password editable in user model in nifty_authentication
6
+
7
+ * adding filter_parameter_logging :password in nifty_authentication
8
+
1
9
  0.2.3 (February 20th, 2009)
2
10
 
3
11
  * fixing nifty_authentication to work with Rails 2.3 application_controller.rb
data/Rakefile CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
2
2
  require 'rake'
3
3
  require 'echoe'
4
4
 
5
- Echoe.new('nifty-generators', '0.2.3') do |p|
5
+ Echoe.new('nifty-generators', '0.2.4') do |p|
6
6
  p.project = "niftygenerators"
7
7
  p.description = "A collection of useful generator scripts for Rails."
8
8
  p.url = "http://github.com/ryanb/nifty-generators"
@@ -1,168 +1,32 @@
1
+ # -*- encoding: utf-8 -*-
1
2
 
2
- # Gem::Specification for Nifty-generators-0.2.3
3
- # Originally generated by Echoe
3
+ Gem::Specification.new do |s|
4
+ s.name = %q{nifty-generators}
5
+ s.version = "0.2.4"
4
6
 
5
- --- !ruby/object:Gem::Specification
6
- name: nifty-generators
7
- version: !ruby/object:Gem::Version
8
- version: 0.2.3
9
- platform: ruby
10
- authors:
11
- - Ryan Bates
12
- autorequire:
13
- bindir: bin
7
+ s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
+ s.authors = ["Ryan Bates"]
9
+ s.date = %q{2009-05-06}
10
+ s.description = %q{A collection of useful generator scripts for Rails.}
11
+ s.email = %q{ryan (at) railscasts (dot) com}
12
+ s.extra_rdoc_files = ["CHANGELOG", "lib/nifty_generators.rb", "LICENSE", "README.rdoc", "tasks/deployment.rake", "TODO"]
13
+ s.files = ["CHANGELOG", "lib/nifty_generators.rb", "LICENSE", "rails_generators/nifty_authentication/lib/insert_commands.rb", "rails_generators/nifty_authentication/nifty_authentication_generator.rb", "rails_generators/nifty_authentication/templates/authentication.rb", "rails_generators/nifty_authentication/templates/fixtures.yml", "rails_generators/nifty_authentication/templates/migration.rb", "rails_generators/nifty_authentication/templates/sessions_controller.rb", "rails_generators/nifty_authentication/templates/sessions_helper.rb", "rails_generators/nifty_authentication/templates/tests/rspec/sessions_controller.rb", "rails_generators/nifty_authentication/templates/tests/rspec/user.rb", "rails_generators/nifty_authentication/templates/tests/rspec/users_controller.rb", "rails_generators/nifty_authentication/templates/tests/shoulda/sessions_controller.rb", "rails_generators/nifty_authentication/templates/tests/shoulda/user.rb", "rails_generators/nifty_authentication/templates/tests/shoulda/users_controller.rb", "rails_generators/nifty_authentication/templates/tests/testunit/sessions_controller.rb", "rails_generators/nifty_authentication/templates/tests/testunit/user.rb", "rails_generators/nifty_authentication/templates/tests/testunit/users_controller.rb", "rails_generators/nifty_authentication/templates/user.rb", "rails_generators/nifty_authentication/templates/users_controller.rb", "rails_generators/nifty_authentication/templates/users_helper.rb", "rails_generators/nifty_authentication/templates/views/erb/login.html.erb", "rails_generators/nifty_authentication/templates/views/erb/signup.html.erb", "rails_generators/nifty_authentication/templates/views/haml/login.html.haml", "rails_generators/nifty_authentication/templates/views/haml/signup.html.haml", "rails_generators/nifty_authentication/USAGE", "rails_generators/nifty_config/nifty_config_generator.rb", "rails_generators/nifty_config/templates/config.yml", "rails_generators/nifty_config/templates/load_config.rb", "rails_generators/nifty_config/USAGE", "rails_generators/nifty_layout/nifty_layout_generator.rb", "rails_generators/nifty_layout/templates/helper.rb", "rails_generators/nifty_layout/templates/layout.html.erb", "rails_generators/nifty_layout/templates/layout.html.haml", "rails_generators/nifty_layout/templates/stylesheet.css", "rails_generators/nifty_layout/templates/stylesheet.sass", "rails_generators/nifty_layout/USAGE", "rails_generators/nifty_scaffold/nifty_scaffold_generator.rb", "rails_generators/nifty_scaffold/templates/actions/create.rb", "rails_generators/nifty_scaffold/templates/actions/destroy.rb", "rails_generators/nifty_scaffold/templates/actions/edit.rb", "rails_generators/nifty_scaffold/templates/actions/index.rb", "rails_generators/nifty_scaffold/templates/actions/new.rb", "rails_generators/nifty_scaffold/templates/actions/show.rb", "rails_generators/nifty_scaffold/templates/actions/update.rb", "rails_generators/nifty_scaffold/templates/controller.rb", "rails_generators/nifty_scaffold/templates/fixtures.yml", "rails_generators/nifty_scaffold/templates/helper.rb", "rails_generators/nifty_scaffold/templates/migration.rb", "rails_generators/nifty_scaffold/templates/model.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/create.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/destroy.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/edit.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/index.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/new.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/show.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/actions/update.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/controller.rb", "rails_generators/nifty_scaffold/templates/tests/rspec/model.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/create.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/destroy.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/edit.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/index.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/new.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/show.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/actions/update.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/controller.rb", "rails_generators/nifty_scaffold/templates/tests/shoulda/model.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/create.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/destroy.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/edit.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/index.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/new.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/show.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/actions/update.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/controller.rb", "rails_generators/nifty_scaffold/templates/tests/testunit/model.rb", "rails_generators/nifty_scaffold/templates/views/erb/_form.html.erb", "rails_generators/nifty_scaffold/templates/views/erb/edit.html.erb", "rails_generators/nifty_scaffold/templates/views/erb/index.html.erb", "rails_generators/nifty_scaffold/templates/views/erb/new.html.erb", "rails_generators/nifty_scaffold/templates/views/erb/show.html.erb", "rails_generators/nifty_scaffold/templates/views/haml/_form.html.haml", "rails_generators/nifty_scaffold/templates/views/haml/edit.html.haml", "rails_generators/nifty_scaffold/templates/views/haml/index.html.haml", "rails_generators/nifty_scaffold/templates/views/haml/new.html.haml", "rails_generators/nifty_scaffold/templates/views/haml/show.html.haml", "rails_generators/nifty_scaffold/USAGE", "Rakefile", "README.rdoc", "tasks/deployment.rake", "test/test_helper.rb", "test/test_nifty_authentication_generator.rb", "test/test_nifty_config_generator.rb", "test/test_nifty_layout_generator.rb", "test/test_nifty_scaffold_generator.rb", "TODO", "Manifest", "nifty-generators.gemspec"]
14
+ s.has_rdoc = true
15
+ s.homepage = %q{http://github.com/ryanb/nifty-generators}
16
+ s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Nifty-generators", "--main", "README.rdoc"]
17
+ s.require_paths = ["lib"]
18
+ s.rubyforge_project = %q{niftygenerators}
19
+ s.rubygems_version = %q{1.3.2}
20
+ s.summary = %q{A collection of useful generator scripts for Rails.}
21
+ s.test_files = ["test/test_helper.rb", "test/test_nifty_authentication_generator.rb", "test/test_nifty_config_generator.rb", "test/test_nifty_layout_generator.rb", "test/test_nifty_scaffold_generator.rb"]
14
22
 
15
- date: 2009-02-20 00:00:00 -08:00
16
- default_executable:
17
- dependencies: []
23
+ if s.respond_to? :specification_version then
24
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
25
+ s.specification_version = 3
18
26
 
19
- description: A collection of useful generator scripts for Rails.
20
- email: ryan (at) railscasts (dot) com
21
- executables: []
22
-
23
- extensions: []
24
-
25
- extra_rdoc_files:
26
- - CHANGELOG
27
- - lib/nifty_generators.rb
28
- - LICENSE
29
- - README.rdoc
30
- - tasks/deployment.rake
31
- - TODO
32
- files:
33
- - CHANGELOG
34
- - lib/nifty_generators.rb
35
- - LICENSE
36
- - rails_generators/nifty_authentication/lib/insert_commands.rb
37
- - rails_generators/nifty_authentication/nifty_authentication_generator.rb
38
- - rails_generators/nifty_authentication/templates/authentication.rb
39
- - rails_generators/nifty_authentication/templates/fixtures.yml
40
- - rails_generators/nifty_authentication/templates/migration.rb
41
- - rails_generators/nifty_authentication/templates/sessions_controller.rb
42
- - rails_generators/nifty_authentication/templates/sessions_helper.rb
43
- - rails_generators/nifty_authentication/templates/tests/rspec/sessions_controller.rb
44
- - rails_generators/nifty_authentication/templates/tests/rspec/user.rb
45
- - rails_generators/nifty_authentication/templates/tests/rspec/users_controller.rb
46
- - rails_generators/nifty_authentication/templates/tests/shoulda/sessions_controller.rb
47
- - rails_generators/nifty_authentication/templates/tests/shoulda/user.rb
48
- - rails_generators/nifty_authentication/templates/tests/shoulda/users_controller.rb
49
- - rails_generators/nifty_authentication/templates/tests/testunit/sessions_controller.rb
50
- - rails_generators/nifty_authentication/templates/tests/testunit/user.rb
51
- - rails_generators/nifty_authentication/templates/tests/testunit/users_controller.rb
52
- - rails_generators/nifty_authentication/templates/user.rb
53
- - rails_generators/nifty_authentication/templates/users_controller.rb
54
- - rails_generators/nifty_authentication/templates/users_helper.rb
55
- - rails_generators/nifty_authentication/templates/views/erb/login.html.erb
56
- - rails_generators/nifty_authentication/templates/views/erb/signup.html.erb
57
- - rails_generators/nifty_authentication/templates/views/haml/login.html.haml
58
- - rails_generators/nifty_authentication/templates/views/haml/signup.html.haml
59
- - rails_generators/nifty_authentication/USAGE
60
- - rails_generators/nifty_config/nifty_config_generator.rb
61
- - rails_generators/nifty_config/templates/config.yml
62
- - rails_generators/nifty_config/templates/load_config.rb
63
- - rails_generators/nifty_config/USAGE
64
- - rails_generators/nifty_layout/nifty_layout_generator.rb
65
- - rails_generators/nifty_layout/templates/helper.rb
66
- - rails_generators/nifty_layout/templates/layout.html.erb
67
- - rails_generators/nifty_layout/templates/layout.html.haml
68
- - rails_generators/nifty_layout/templates/stylesheet.css
69
- - rails_generators/nifty_layout/templates/stylesheet.sass
70
- - rails_generators/nifty_layout/USAGE
71
- - rails_generators/nifty_scaffold/nifty_scaffold_generator.rb
72
- - rails_generators/nifty_scaffold/templates/actions/create.rb
73
- - rails_generators/nifty_scaffold/templates/actions/destroy.rb
74
- - rails_generators/nifty_scaffold/templates/actions/edit.rb
75
- - rails_generators/nifty_scaffold/templates/actions/index.rb
76
- - rails_generators/nifty_scaffold/templates/actions/new.rb
77
- - rails_generators/nifty_scaffold/templates/actions/show.rb
78
- - rails_generators/nifty_scaffold/templates/actions/update.rb
79
- - rails_generators/nifty_scaffold/templates/controller.rb
80
- - rails_generators/nifty_scaffold/templates/fixtures.yml
81
- - rails_generators/nifty_scaffold/templates/helper.rb
82
- - rails_generators/nifty_scaffold/templates/migration.rb
83
- - rails_generators/nifty_scaffold/templates/model.rb
84
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/create.rb
85
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/destroy.rb
86
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/edit.rb
87
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/index.rb
88
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/new.rb
89
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/show.rb
90
- - rails_generators/nifty_scaffold/templates/tests/rspec/actions/update.rb
91
- - rails_generators/nifty_scaffold/templates/tests/rspec/controller.rb
92
- - rails_generators/nifty_scaffold/templates/tests/rspec/model.rb
93
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/create.rb
94
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/destroy.rb
95
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/edit.rb
96
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/index.rb
97
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/new.rb
98
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/show.rb
99
- - rails_generators/nifty_scaffold/templates/tests/shoulda/actions/update.rb
100
- - rails_generators/nifty_scaffold/templates/tests/shoulda/controller.rb
101
- - rails_generators/nifty_scaffold/templates/tests/shoulda/model.rb
102
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/create.rb
103
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/destroy.rb
104
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/edit.rb
105
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/index.rb
106
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/new.rb
107
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/show.rb
108
- - rails_generators/nifty_scaffold/templates/tests/testunit/actions/update.rb
109
- - rails_generators/nifty_scaffold/templates/tests/testunit/controller.rb
110
- - rails_generators/nifty_scaffold/templates/tests/testunit/model.rb
111
- - rails_generators/nifty_scaffold/templates/views/erb/_form.html.erb
112
- - rails_generators/nifty_scaffold/templates/views/erb/edit.html.erb
113
- - rails_generators/nifty_scaffold/templates/views/erb/index.html.erb
114
- - rails_generators/nifty_scaffold/templates/views/erb/new.html.erb
115
- - rails_generators/nifty_scaffold/templates/views/erb/show.html.erb
116
- - rails_generators/nifty_scaffold/templates/views/haml/_form.html.haml
117
- - rails_generators/nifty_scaffold/templates/views/haml/edit.html.haml
118
- - rails_generators/nifty_scaffold/templates/views/haml/index.html.haml
119
- - rails_generators/nifty_scaffold/templates/views/haml/new.html.haml
120
- - rails_generators/nifty_scaffold/templates/views/haml/show.html.haml
121
- - rails_generators/nifty_scaffold/USAGE
122
- - Rakefile
123
- - README.rdoc
124
- - tasks/deployment.rake
125
- - test/test_helper.rb
126
- - test/test_nifty_authentication_generator.rb
127
- - test/test_nifty_config_generator.rb
128
- - test/test_nifty_layout_generator.rb
129
- - test/test_nifty_scaffold_generator.rb
130
- - TODO
131
- - Manifest
132
- - nifty-generators.gemspec
133
- has_rdoc: true
134
- homepage: http://github.com/ryanb/nifty-generators
135
- post_install_message:
136
- rdoc_options:
137
- - --line-numbers
138
- - --inline-source
139
- - --title
140
- - Nifty-generators
141
- - --main
142
- - README.rdoc
143
- require_paths:
144
- - lib
145
- required_ruby_version: !ruby/object:Gem::Requirement
146
- requirements:
147
- - - ">="
148
- - !ruby/object:Gem::Version
149
- version: "0"
150
- version:
151
- required_rubygems_version: !ruby/object:Gem::Requirement
152
- requirements:
153
- - - ">="
154
- - !ruby/object:Gem::Version
155
- version: "1.2"
156
- version:
157
- requirements: []
158
-
159
- rubyforge_project: niftygenerators
160
- rubygems_version: 1.3.1
161
- specification_version: 2
162
- summary: A collection of useful generator scripts for Rails.
163
- test_files:
164
- - test/test_helper.rb
165
- - test/test_nifty_authentication_generator.rb
166
- - test/test_nifty_config_generator.rb
167
- - test/test_nifty_layout_generator.rb
168
- - test/test_nifty_scaffold_generator.rb
27
+ if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
28
+ else
29
+ end
30
+ else
31
+ end
32
+ end
@@ -17,6 +17,7 @@
17
17
  module Authentication
18
18
  def self.included(controller)
19
19
  controller.send :helper_method, :current_<%= user_singular_name %>, :logged_in?
20
+ controller.filter_parameter_logging :password
20
21
  end
21
22
 
22
23
  def current_<%= user_singular_name %>
@@ -3,7 +3,7 @@ class <%= user_class_name %> < ActiveRecord::Base
3
3
  attr_accessible :username, :email, :password, :password_confirmation
4
4
 
5
5
  attr_accessor :password
6
- before_create :prepare_password
6
+ before_save :prepare_password
7
7
 
8
8
  validates_presence_of :username
9
9
  validates_uniqueness_of :username, :email, :allow_blank => true
@@ -26,8 +26,10 @@ class <%= user_class_name %> < ActiveRecord::Base
26
26
  private
27
27
 
28
28
  def prepare_password
29
- self.password_salt = Digest::SHA1.hexdigest([Time.now, rand].join)
30
- self.password_hash = encrypt_password(password)
29
+ unless password.blank?
30
+ self.password_salt = Digest::SHA1.hexdigest([Time.now, rand].join)
31
+ self.password_hash = encrypt_password(password)
32
+ end
31
33
  end
32
34
 
33
35
  def encrypt_password(pass)
@@ -143,11 +143,19 @@ class NiftyScaffoldGenerator < Rails::Generator::Base
143
143
  end
144
144
  end
145
145
 
146
+ def items_path(suffix = 'path')
147
+ if action? :index
148
+ "#{plural_name}_#{suffix}"
149
+ else
150
+ "root_#{suffix}"
151
+ end
152
+ end
153
+
146
154
  def item_path(suffix = 'path')
147
155
  if action? :show
148
156
  "@#{singular_name}"
149
157
  else
150
- "#{plural_name}_#{suffix}"
158
+ items_path(suffix)
151
159
  end
152
160
  end
153
161
 
@@ -155,7 +163,7 @@ class NiftyScaffoldGenerator < Rails::Generator::Base
155
163
  if action? :show
156
164
  "#{singular_name}_#{suffix}(assigns[:#{singular_name}])"
157
165
  else
158
- "#{plural_name}_#{suffix}"
166
+ items_path(suffix)
159
167
  end
160
168
  end
161
169
 
@@ -163,7 +171,7 @@ class NiftyScaffoldGenerator < Rails::Generator::Base
163
171
  if action? :show
164
172
  "#{singular_name}_#{suffix}(assigns(:#{singular_name}))"
165
173
  else
166
- "#{plural_name}_#{suffix}"
174
+ items_path(suffix)
167
175
  end
168
176
  end
169
177
 
@@ -2,5 +2,5 @@
2
2
  @<%= singular_name %> = <%= class_name %>.find(params[:id])
3
3
  @<%= singular_name %>.destroy
4
4
  flash[:notice] = "Successfully destroyed <%= name.humanize.downcase %>."
5
- redirect_to <%= plural_name %>_url
5
+ redirect_to <%= items_path('url') %>
6
6
  end
@@ -1,6 +1,6 @@
1
1
  it "destroy action should destroy model and redirect to index action" do
2
2
  <%= singular_name %> = <%= class_name %>.first
3
3
  delete :destroy, :id => <%= singular_name %>
4
- response.should redirect_to(<%= plural_name %>_url)
4
+ response.should redirect_to(<%= items_path('url') %>)
5
5
  <%= class_name %>.exists?(<%= singular_name %>.id).should be_false
6
6
  end
@@ -2,7 +2,7 @@
2
2
  should "destroy model and redirect to index action" do
3
3
  <%= singular_name %> = <%= class_name %>.first
4
4
  delete :destroy, :id => <%= singular_name %>
5
- assert_redirected_to <%= plural_name %>_url
5
+ assert_redirected_to <%= items_path('url') %>
6
6
  assert !<%= class_name %>.exists?(<%= singular_name %>.id)
7
7
  end
8
8
  end
@@ -1,6 +1,6 @@
1
1
  def test_destroy
2
2
  <%= singular_name %> = <%= class_name %>.first
3
3
  delete :destroy, :id => <%= singular_name %>
4
- assert_redirected_to <%= plural_name %>_url
4
+ assert_redirected_to <%= items_path('url') %>
5
5
  assert !<%= class_name %>.exists?(<%= singular_name %>.id)
6
6
  end
@@ -139,7 +139,7 @@ class TestNiftyScaffoldGenerator < Test::Unit::TestCase
139
139
  assert_match "@line_item = LineItem.new(params[:line_item])", body
140
140
  assert_match "if @line_item.save", body
141
141
  assert_match "flash[:notice] = \"Successfully created line item.\"", body
142
- assert_match "redirect_to line_items_url", body
142
+ assert_match "redirect_to root_url", body
143
143
  assert_match "render :action => 'new'", body
144
144
  end
145
145
  end
@@ -164,7 +164,7 @@ class TestNiftyScaffoldGenerator < Test::Unit::TestCase
164
164
  assert_match "def update", body
165
165
  assert_match "if @line_item.update_attributes(params[:line_item])", body
166
166
  assert_match "flash[:notice] = \"Successfully updated line item.\"", body
167
- assert_match "redirect_to line_items_url", body
167
+ assert_match "redirect_to root_url", body
168
168
  assert_match "render :action => 'edit'", body
169
169
  end
170
170
  end
@@ -181,7 +181,7 @@ class TestNiftyScaffoldGenerator < Test::Unit::TestCase
181
181
  assert_match "@line_item = LineItem.find(params[:id])", body
182
182
  assert_match "@line_item.destroy", body
183
183
  assert_match "flash[:notice] = \"Successfully destroyed line item.\"", body
184
- assert_match "redirect_to line_items_url", body
184
+ assert_match "redirect_to root_url", body
185
185
  end
186
186
  end
187
187
  end
@@ -256,6 +256,7 @@ class TestNiftyScaffoldGenerator < Test::Unit::TestCase
256
256
  assert_generated_file "app/controllers/line_items_controller.rb" do |body|
257
257
  assert_match "def create", body
258
258
  assert_match "def update", body
259
+ assert_match "root_url", body
259
260
  end
260
261
  end
261
262
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nifty-generators
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.3
4
+ version: 0.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Bates
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-02-20 00:00:00 -08:00
12
+ date: 2009-05-06 00:00:00 -07:00
13
13
  default_executable:
14
14
  dependencies: []
15
15
 
@@ -129,6 +129,8 @@ files:
129
129
  - nifty-generators.gemspec
130
130
  has_rdoc: true
131
131
  homepage: http://github.com/ryanb/nifty-generators
132
+ licenses: []
133
+
132
134
  post_install_message:
133
135
  rdoc_options:
134
136
  - --line-numbers
@@ -154,9 +156,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
154
156
  requirements: []
155
157
 
156
158
  rubyforge_project: niftygenerators
157
- rubygems_version: 1.3.1
159
+ rubygems_version: 1.3.2
158
160
  signing_key:
159
- specification_version: 2
161
+ specification_version: 3
160
162
  summary: A collection of useful generator scripts for Rails.
161
163
  test_files:
162
164
  - test/test_helper.rb