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:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-04-07 06:09:15 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-04-07 06:09:15 +0300
commit7ba5b9babaa5802c39e686c57cbf4a3f4725c4b0 (patch)
tree03a696c26f32e46faa46dd12d0a937d1d0d1cba4 /spec/services/issues
parentb56027c9d80ac0e297ba8a43c81e8504172dbf9f (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/services/issues')
-rw-r--r--spec/services/issues/create_service_spec.rb17
1 files changed, 9 insertions, 8 deletions
diff --git a/spec/services/issues/create_service_spec.rb b/spec/services/issues/create_service_spec.rb
index 09fff389cec..a316c8a4219 100644
--- a/spec/services/issues/create_service_spec.rb
+++ b/spec/services/issues/create_service_spec.rb
@@ -383,20 +383,21 @@ describe Issues::CreateService do
context 'when recaptcha was verified' do
let(:log_user) { user }
let(:spam_logs) { create_list(:spam_log, 2, user: log_user, title: 'Awesome issue') }
+ let(:target_spam_log) { spam_logs.last }
before do
opts[:recaptcha_verified] = true
- opts[:spam_log_id] = spam_logs.last.id
+ opts[:spam_log_id] = target_spam_log.id
expect(Spam::AkismetService).not_to receive(:new)
end
- it 'does no mark an issue as a spam ' do
+ it 'does not mark an issue as spam' do
expect(issue).not_to be_spam
end
- it 'an issue is valid ' do
- expect(issue.valid?).to be_truthy
+ it 'issue is valid ' do
+ expect(issue).to be_valid
end
it 'does not assign a spam_log to an issue' do
@@ -431,7 +432,7 @@ describe Issues::CreateService do
end
context 'when issuables_recaptcha_enabled feature flag is true' do
- it 'marks an issue as a spam ' do
+ it 'marks an issue as spam' do
expect(issue).to be_spam
end
@@ -444,7 +445,7 @@ describe Issues::CreateService do
.to have_spam_log(title: issue.title, description: issue.description, user_id: user.id, noteable_type: 'Issue')
end
- it 'assigns a spam_log to an issue' do
+ it 'assigns a spam_log to the issue' do
expect(issue.spam_log).to eq(SpamLog.last)
end
end
@@ -454,7 +455,7 @@ describe Issues::CreateService do
stub_feature_flags(allow_possible_spam: true)
end
- it 'does not mark an issue as a spam ' do
+ it 'does not mark an issue as spam' do
expect(issue).not_to be_spam
end
@@ -480,7 +481,7 @@ describe Issues::CreateService do
end
end
- it 'does not mark an issue as a spam ' do
+ it 'does not mark an issue as spam' do
expect(issue).not_to be_spam
end