This project is archived and is in readonly mode.
g.fixture_replacement ignored
Reported by Joe F. | February 12th, 2010 @ 12:09 AM
My config/application.rb has:
config.generators do |g|
g.fixture_replacement :factory_girl
end
and I have factory_girl generators downloaded from: http://github.com/indirect/rails3-generators
If I run
rails generate scaffold Article title:string body:text
it creates a yml fixture. If I run it with
--fixture-replacement=factory_girl
then it works. Sounds to me like it's ignoring g.fixture_replacement. Tried to dig into the code, unfortunately didn't have time to figure out the method_missing call in Rails::Configuration::Generators. Any thoughts?
Comments and changes to this ticket
-
jduff September 12th, 2010 @ 09:06 PM
The syntax changed slightly it seems, this works:
config.generators do |g| g.test_framework :test_unit, :fixture_replacement=>:factory_girl end
-
Rohit Arondekar September 13th, 2010 @ 01:58 AM
- Importance changed from to Low
Joe, does the above code work for you?
-
David Trasbo September 20th, 2010 @ 07:48 PM
- State changed from new to invalid
Using the option syntax works on master.
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>