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:
authorMark Chao <mchao@gitlab.com>2018-07-19 05:43:17 +0300
committerMark Chao <mchao@gitlab.com>2018-08-07 11:53:44 +0300
commit35e029009d3d4cc19a4645538e1f4b19e69c8a51 (patch)
tree708605d6d84a50089e95a999a599a6ff06678613 /spec/support/shared_examples/services
parentbd6f1ceb27a9179f91c3480b532210c26c82d39d (diff)
Convert use of any_instance as it does not work with prepend
Diffstat (limited to 'spec/support/shared_examples/services')
-rw-r--r--spec/support/shared_examples/services/boards/issues_move_service.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/support/shared_examples/services/boards/issues_move_service.rb b/spec/support/shared_examples/services/boards/issues_move_service.rb
index 737863ea411..6d29a97c56d 100644
--- a/spec/support/shared_examples/services/boards/issues_move_service.rb
+++ b/spec/support/shared_examples/services/boards/issues_move_service.rb
@@ -4,7 +4,9 @@ shared_examples 'issues move service' do |group|
let(:params) { { board_id: board1.id, from_list_id: list1.id, to_list_id: list2.id } }
it 'delegates the label changes to Issues::UpdateService' do
- expect_any_instance_of(Issues::UpdateService).to receive(:execute).with(issue).once
+ service = double(:service)
+ expect(Issues::UpdateService).to receive(:new).and_return(service)
+ expect(service).to receive(:execute).with(issue).once
described_class.new(parent, user, params).execute(issue)
end