get :show, {:id => subcategory.id.to_s, :params => {:sort => 'title'}}
Must be
get :show, :id => subcategory.id.to_s, :sort => 'title'
If you do not want to pass params[:params][:sort] .
Besides
helper.params[:sort].should_not be_nil
Must be
controller.params[:sort].should_not be_nil controller.params[:sort].should eql 'title'
(If you want to check the helper, you have to write an auxiliary specification.)
jdeseno Nov 25 '11 at 20:11 2011-11-25 20:11
source share