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:
authorKerri Miller <kerrizor@kerrizor.com>2019-06-04 17:50:41 +0300
committerKerri Miller <kerrizor@kerrizor.com>2019-06-06 02:19:45 +0300
commitbd624741a170a30c965ff1a2bcf9a0ae1bc763e3 (patch)
tree45fceb5c3b91498b961e0e78c97a27ae836fa91e /spec/services/suggestions
parentfb3d40cb61eaff46bc10d3d49d499bd5d34a6be1 (diff)
Remove 2nd stub expectation of #last_diff_file
It looks to be a stub/mock rather than strictly an expectation of the system, so dropping this to only a single invocation expected, as we've removed one of the two places #last_diff_file would be invoked.
Diffstat (limited to 'spec/services/suggestions')
-rw-r--r--spec/services/suggestions/create_service_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/services/suggestions/create_service_spec.rb b/spec/services/suggestions/create_service_spec.rb
index ccd44e615a8..d95f9e3349b 100644
--- a/spec/services/suggestions/create_service_spec.rb
+++ b/spec/services/suggestions/create_service_spec.rb
@@ -96,7 +96,7 @@ describe Suggestions::CreateService do
it 'creates no suggestion when diff file is not found' do
expect_next_instance_of(DiffNote) do |diff_note|
- expect(diff_note).to receive(:latest_diff_file).twice { nil }
+ expect(diff_note).to receive(:latest_diff_file).once { nil }
end
expect { subject.execute }.not_to change(Suggestion, :count)