Add test for user log_out user#destroy

This commit is contained in:
SarvarKhalimov
2022-01-10 22:50:44 +05:00
parent 5523b91364
commit 6c559995ab

View File

@@ -30,4 +30,13 @@ describe Spree::UserSessionsController, type: :controller do
end
end
end
describe "destroy" do
it "redirects to root with flash message" do
spree_post :destroy
expect(response).to redirect_to root_path
expect(flash[:notice]).to eq "Signed out successfully."
end
end
end