I’m using Test::Unit with shoulda to test a controller.
Since I’m just testing the controller I dont wanna the view to be rendered.
I’m stubbing some objects, some errors are throw when the view is rendered, but the test shouldn’t fail, because the controller is correct.
So, theres any way to disable the rendering of a template/view, from my tests?
I heard that rSpec works like that.
If you’re using Mocha, it’s easy. Add this to your individual test or your setup method:
If you’re not, well, use Mocha.
Then in your test_helper.rb