Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Framework Counseling

Framework Counseling

An 8th Light University session led by Paul Pagel and Mike Jansen on the pros and cons of frameworks, and how you can separate your application from the framework.

Focus is on Rails and Ruby in this presentation.

Video: http://vimeo.com/47937434

Avatar for mjansen401

mjansen401

August 17, 2012
Tweet

Other Decks in Programming

Transcript

  1. Slow tests Finished in 5 minutes 17.32 seconds 3429 examples,

    0 failures Finished in 0.23763 seconds 3 examples, 0 failures real 0m10.354s user 0m8.417s sys 0m1.454s Wednesday, August 22, 12
  2. Separation of Data and Behavior class Feedback validates_numericality_of :rating, :allow_nil

    => true, :only_integer =>true, :greater_than_or_equal_to => 0, :less_than_or_equal_to => 10, :message => "Invalid rating." Wednesday, August 22, 12
  3. Separation of Data and Behavior def create_measurables @measurables.each_pair do |key,

    value| validator = create_validator_from(key, value) measurable = @client.measurables.find_or_initialize_by_key(key) if validator.valid? measurable.measurement = value measurable.save! end end end Wednesday, August 22, 12
  4. You can decouple your application from the framework. It doesn’t

    require a rewrite. Wednesday, August 22, 12