Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/support/shared_contexts/spam_constants.rb')
-rw-r--r--spec/support/shared_contexts/spam_constants.rb9
1 files changed, 6 insertions, 3 deletions
diff --git a/spec/support/shared_contexts/spam_constants.rb b/spec/support/shared_contexts/spam_constants.rb
index b6e92ea3050..32371f4b92f 100644
--- a/spec/support/shared_contexts/spam_constants.rb
+++ b/spec/support/shared_contexts/spam_constants.rb
@@ -1,7 +1,10 @@
# frozen_string_literal: true
shared_context 'includes Spam constants' do
- REQUIRE_RECAPTCHA = Spam::SpamConstants::REQUIRE_RECAPTCHA
- DISALLOW = Spam::SpamConstants::DISALLOW
- ALLOW = Spam::SpamConstants::ALLOW
+ before do
+ stub_const('CONDITIONAL_ALLOW', Spam::SpamConstants::CONDITIONAL_ALLOW)
+ stub_const('DISALLOW', Spam::SpamConstants::DISALLOW)
+ stub_const('ALLOW', Spam::SpamConstants::ALLOW)
+ stub_const('BLOCK_USER', Spam::SpamConstants::BLOCK_USER)
+ end
end