Robert Walker wrote: > If you have written your Cucumber stories and/or RSpec examples before > all this work, using them to drive your design, then you are on the > right track to good practice and design.
Thats great advice and was on my list of 'when i've got the basics down i need to go and learn about....' list. Sounds like I should probably make it a priority. the later examples you gavce helped reinforce this for me. > The current trend in Rails is toward has_many :through instead of > has_and_belongs_to_many (HABTM). The has_many :trough is more flexible, > and often more RESTful. I did pick up on this during some reading i did this morning (Colin's suggestion to read the ActiveRecord Associations guide helped me better understand). As this is a very simple system that i have no plans to extend (famous last words hehe) i felt HABTM fitted the bill. > The latest version of Rails has a convention for this, and an associated > rake task. The feature is called "Seeds." You'll notice there will be a > db/seeds.rb file for putting your Ruby code to populate your seed data. > Then you can run rake db:seed after running rake db:migrate to execute > the data seeds. Brilliant! Thank you for the pointer. > This is often referred to as "skinny controller, fat model design," and > is typically promoted in Rails as a "best practice." aha (penny starting to drop here) Thanks for taking the time to read this and i really appreciate all the responses and advice. -- Posted via http://www.ruby-forum.com/.
-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

