class OauthClientsControllerDestroyTest
Public Instance Methods
do_delete()
click to toggle source
# File lib/generators/test_unit/templates/clients_controller_test.rb, line 215 def do_delete delete :destroy,:id=>'3' end
setup()
click to toggle source
# File lib/generators/test_unit/templates/clients_controller_test.rb, line 206 def setup @controller = OauthClientsController.new @request = ActionController::TestRequest.new @response = ActionController::TestResponse.new login_as_application_owner @client_application.stubs(:destroy) end
test_should_destroy_client_applications()
click to toggle source
# File lib/generators/test_unit/templates/clients_controller_test.rb, line 225 def test_should_destroy_client_applications @client_application.expects(:destroy) do_delete end
test_should_query_current_users_client_applications()
click to toggle source
# File lib/generators/test_unit/templates/clients_controller_test.rb, line 219 def test_should_query_current_users_client_applications @user.expects(:client_applications).returns(@client_applications) @client_applications.expects(:find).with('3').returns(@client_application) do_delete end
test_should_redirect_to_list()
click to toggle source
# File lib/generators/test_unit/templates/clients_controller_test.rb, line 230 def test_should_redirect_to_list do_delete assert_response :redirect assert_redirected_to :action => 'index' end