summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2018-05-24 16:24:18 +0000
committerRémy Coutable <remy@rymai.me>2018-05-24 16:24:18 +0000
commit96f54853e28acff5ca4801c6b420ea96521af35b (patch)
tree6c52560a77dc3ac947844f81573cc3b8e5154d8a /spec
parent0279a72752e17d773c81c46c602204c318fd1ecd (diff)
parenta7225111b16eb5f8f6f00a6ea2a844ea94e50b5e (diff)
downloadgitlab-ce-96f54853e28acff5ca4801c6b420ea96521af35b.tar.gz
Merge branch 'ce-6127-move-merge-requests-services' into 'master'
CE: Extract EE specific files/lines for some merge requests files See merge request gitlab-org/gitlab-ce!19107
Diffstat (limited to 'spec')
-rw-r--r--spec/workers/update_merge_requests_worker_spec.rb9
1 files changed, 7 insertions, 2 deletions
diff --git a/spec/workers/update_merge_requests_worker_spec.rb b/spec/workers/update_merge_requests_worker_spec.rb
index 0fa19ac84bb..80137815d2b 100644
--- a/spec/workers/update_merge_requests_worker_spec.rb
+++ b/spec/workers/update_merge_requests_worker_spec.rb
@@ -18,8 +18,13 @@ describe UpdateMergeRequestsWorker do
end
it 'executes MergeRequests::RefreshService with expected values' do
- expect(MergeRequests::RefreshService).to receive(:new).with(project, user).and_call_original
- expect_any_instance_of(MergeRequests::RefreshService).to receive(:execute).with(oldrev, newrev, ref)
+ expect(MergeRequests::RefreshService).to receive(:new)
+ .with(project, user).and_wrap_original do |method, *args|
+ method.call(*args).tap do |refresh_service|
+ expect(refresh_service)
+ .to receive(:execute).with(oldrev, newrev, ref)
+ end
+ end
perform
end