Commit f64bdd5e
Changed files (2)
app
models
spec
controllers
app/models/tutorial.rb
@@ -4,6 +4,6 @@ class Tutorial < ActiveRecord::Base
acts_as_taggable
def to_param
- "#{id}-#{description.gsub(/[^a-z0-9]+/i, '-')}"
+ "#{id}-#{heading.gsub(/[^a-z0-9]+/i, '-')}"
end
end
spec/controllers/tutorials_controller_spec.rb
@@ -2,16 +2,10 @@ require 'spec_helper'
describe TutorialsController do
- # This should return the minimal set of attributes required to create a valid
- # Tutorial. As you add validations to Tutorial, be sure to
- # update the return value of this method accordingly.
def valid_attributes
- {}
+ {:heading => "hello world"}
end
- # This should return the minimal set of values that should be in the session
- # in order to pass any filters (e.g. authentication) defined in
- # TutorialsController. Be sure to keep this updated too.
def valid_session
{}
end