Undefined method: controller_name

David C. wrote:

On Dec 12, 2007 9:50 AM, Alvin S. <a.schur at nucleus.com http://rubyforge.org/mailman/listinfo/rspec-users> wrote:

/ With rspec 1.0.8 I have a spec in the directory:
/> >/ spec/units/controllers/application_controller_spec.rb
/> >/
/> >/ require File.dirname(FILE) + ‘/…/…/spec_helper’
/> >/
/> >/ class DummyController < ApplicationController
/> >/ def index
/> >/ raise “Prevent index from rendering”
/> >/ end
/> >/ end
/> >/
/> >/ describe ApplicationController, “Handling errors in production”,
/> >/ :behaviour_type => :controller do
/>
Try :type instead and see if that works.

This did work, thanks.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs