require 'test_helper' class BooksControllerTest < ActionController::TestCase test "should catch the error" do assert_nothing_raised do get :show, :id => 123 end end end