diff --git a/ee/app/services/ee/users/auto_ban_service.rb b/ee/app/services/ee/users/auto_ban_service.rb index 781eec3b6da5fda860c2b41d99f07ceb3b4a36bd..1e9b0cb57c0da2fd6a15a5ef110e881fd932152c 100644 --- a/ee/app/services/ee/users/auto_ban_service.rb +++ b/ee/app/services/ee/users/auto_ban_service.rb @@ -22,7 +22,7 @@ def execute! private def send_truth_data - return unless ::Feature.enabled?(:arkose_truth_data_auto_ban, user, type: :gitlab_com_derisk) + return unless ::Gitlab::Saas.feature_available?(:identity_verification) Arkose::TruthDataService.new(user: user, is_legit: false).execute end diff --git a/ee/config/feature_flags/gitlab_com_derisk/arkose_truth_data_auto_ban.yml b/ee/config/feature_flags/gitlab_com_derisk/arkose_truth_data_auto_ban.yml deleted file mode 100644 index 6eaab44a8d115fbfbc599b8b1ea00ab56a95c54e..0000000000000000000000000000000000000000 --- a/ee/config/feature_flags/gitlab_com_derisk/arkose_truth_data_auto_ban.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -name: arkose_truth_data_auto_ban -feature_issue_url: https://gitlab.com/gitlab-org/modelops/anti-abuse/team-tasks/-/issues/548 -introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/157082 -rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/468491 -milestone: '17.2' -group: group::anti-abuse -type: gitlab_com_derisk -default_enabled: false diff --git a/ee/spec/services/ee/users/auto_ban_service_spec.rb b/ee/spec/services/ee/users/auto_ban_service_spec.rb index 32e7ebc89260e9f57ac9c463dffa528ab71d9c96..863398111ab55ba3b5db7d8d4700d035074bea10 100644 --- a/ee/spec/services/ee/users/auto_ban_service_spec.rb +++ b/ee/spec/services/ee/users/auto_ban_service_spec.rb @@ -8,7 +8,7 @@ let(:service) { described_class.new(user: user, reason: reason) } shared_examples 'executing the service' do - context 'when the feature is enabled' do + context 'when running in SAAS', :saas do it 'executes the Arkose truth data service' do expect_next_instance_of(Arkose::TruthDataService, user: user, is_legit: false) do |instance| expect(instance).to receive(:execute) @@ -18,12 +18,8 @@ end end - context 'when the feature is not enabled' do - before do - stub_feature_flags(arkose_truth_data_auto_ban: false) - end - - it 'does not execute the arkose truth data service' do + context 'when not running in SAAS' do + it 'does not execute the Arkose truth data service' do expect(Arkose::TruthDataService).not_to receive(:new) subject