This project is archived and is in readonly mode.
[Patch] --skip-helper for controller tests
Reported by Dan Pickett | August 8th, 2009 @ 07:11 PM
patch attached
Generally, I like to make my helpers domain specific and I don't always have a need for them when I generate my controllers. It ultimately results in a lot of cruft in my app/helpers directory
This --skip-helper will omit the helper and the helper test from the files that are generated.
Arguably, I'd like to make this the default, but I realize that might be a little dramatic.
Comments and changes to this ticket
-
José Valim August 8th, 2009 @ 07:21 PM
Already working on Rails 3.0. You can try to convince some from core to get them applied on Rails 2.3. :)
-
Josh Nichols August 8th, 2009 @ 08:03 PM
+1, because if I usually immediately delete the generated helper.
-
Dan Croak August 8th, 2009 @ 08:12 PM
-1
While I agree on not producing helpers, I write my own generators to override things like this.
I say: "use a custom generator or wait until Rails 3.0." This doesn't need to be in Rails 2.3.
-
Steve St. Martin August 8th, 2009 @ 08:31 PM
-1 I usually delete helpers as well, however I think this feature can wait till 3.0 as this is a change in behavior and not really a bug (is there a possibility this might break anyones custom generators?).
-
AmundS August 9th, 2009 @ 01:33 AM
+1 helpers usually sit empty, more often than not I don't need them.
-
Dmitry Ratnikov August 9th, 2009 @ 04:23 AM
+1 since helpers are usually empty and in the event that you do want to generate them, should have also generated a corresponding helper unit test. That is currently not done anyway.
-
Derander August 9th, 2009 @ 09:20 PM
+1 verified on 2-3-stable.
This is a simple change that won't break anything to make some people's lives better on 2.3.
-
Elad Meidar August 9th, 2009 @ 10:05 PM
+1 Verified on 2-3-stable, tested manually as well.
good to know generators are getting smarter on 3.0
-
Jeremy Kemper August 10th, 2009 @ 06:51 AM
- Tag changed from 2.3.x, bugmash to 2.3.x
- State changed from new to wontfix
I'd rather not pile on more options. How often are you even going to remember to provide it? Deleting the file is simple enough.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>