From 037622fc7ff50adb03cedbca74738b52a1be21f1 Mon Sep 17 00:00:00 2001 From: Roman Rizzi Date: Mon, 4 Dec 2023 12:44:32 -0300 Subject: [PATCH] DEV: reviewable_user spec should assert on delete_user_block instead of delete_user (#24692) --- spec/models/reviewable_user_spec.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/spec/models/reviewable_user_spec.rb b/spec/models/reviewable_user_spec.rb index 7b0249509f6..e0e56f718da 100644 --- a/spec/models/reviewable_user_spec.rb +++ b/spec/models/reviewable_user_spec.rb @@ -26,7 +26,7 @@ RSpec.describe ReviewableUser, type: :model do expect(actions.has?(:delete_user_block)).to eq(false) end - it "can delete a user without a giving a rejection reason if the user was a spammer" do + it "doesn't ask for a rejection reason when deleting a user who was flagged as a possible spammer" do reviewable.reviewable_scores.build(user: admin, reason: "suspect_user") assert_require_reject_reason(:delete_user, false) @@ -36,10 +36,10 @@ RSpec.describe ReviewableUser, type: :model do assert_require_reject_reason(:delete_user, true) end - it "can delete and block a user without giving a rejection reason if the user was a spammer" do + it "doesn't ask for a rejection reason when blocking a user who was flagged as a possible spammer" do reviewable.reviewable_scores.build(user: admin, reason: "suspect_user") - assert_require_reject_reason(:delete_user, false) + assert_require_reject_reason(:delete_user_block, false) end it "requires a rejection reason to delete and block a user" do