I have a User controller where users aren't added with the usual new/create actions. I'm trying to set it so that it raises when 'new' is called but it doesn't seem to be working - here's the method, test and test result. Can anyone see why it's not working?<br>
<br>#in controller<br> def new<br> raise "Users should be added with 'batch_add' rather than 'new"<br> end<br><br>#test<br> describe "/new" do<br> it "should raise an error when called" do<br>
lambda{get('new')}.should raise_error(RuntimeError)<br> end<br> end<br><br>#test report<br>'Admin::UserController /new should raise an error when called' FAILED<br>expected RuntimeError but nothing was raised<br>
<br>