From 728df21e56e54b253c269e7c8fa349a80ef43d61 Mon Sep 17 00:00:00 2001 From: Lynn Hurley Date: Tue, 27 Oct 2015 03:05:57 -0500 Subject: [PATCH] fix broken test --- .../devise_token_auth/registrations_controller_test.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/controllers/devise_token_auth/registrations_controller_test.rb b/test/controllers/devise_token_auth/registrations_controller_test.rb index 574e437ff..abc7a1c31 100644 --- a/test/controllers/devise_token_auth/registrations_controller_test.rb +++ b/test/controllers/devise_token_auth/registrations_controller_test.rb @@ -763,13 +763,15 @@ class DeviseTokenAuth::RegistrationsControllerTest < ActionDispatch::Integration end test "Mang should be destroyed" do + @resource.skip_confirmation! + @resource.save! @auth_headers = @resource.create_new_auth_token @client_id = @auth_headers['client'] # ensure request is not treated as batch request age_token(@resource, @client_id) - delete "/mangs", {}, @auth_headers + xhr :delete, "/mangs", {}, @auth_headers assert_equal 200, response.status refute Mang.where(id: @resource.id).first