summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/services/groups/destroy_service_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/services/groups/destroy_service_spec.rb b/spec/services/groups/destroy_service_spec.rb
index d80d0f5a8a8..97a88b5d697 100644
--- a/spec/services/groups/destroy_service_spec.rb
+++ b/spec/services/groups/destroy_service_spec.rb
@@ -35,6 +35,14 @@ describe Groups::DestroyService do
it { expect(NotificationSetting.unscoped.all).not_to include(notification_setting) }
end
+ context 'site statistics' do
+ it 'doesnt trigger project deletion hooks twice' do
+ expect_any_instance_of(Project).to receive(:untrack_site_statistics).once
+
+ destroy_group(group, user, async)
+ end
+ end
+
context 'mattermost team' do
let!(:chat_team) { create(:chat_team, namespace: group) }