diff options
Diffstat (limited to 'spec/workers/merge_requests/set_reviewer_reviewed_worker_spec.rb')
-rw-r--r-- | spec/workers/merge_requests/set_reviewer_reviewed_worker_spec.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/workers/merge_requests/set_reviewer_reviewed_worker_spec.rb b/spec/workers/merge_requests/set_reviewer_reviewed_worker_spec.rb index 942cf8e87e9..7341a0dcc5b 100644 --- a/spec/workers/merge_requests/set_reviewer_reviewed_worker_spec.rb +++ b/spec/workers/merge_requests/set_reviewer_reviewed_worker_spec.rb @@ -14,21 +14,21 @@ RSpec.describe MergeRequests::SetReviewerReviewedWorker, feature_category: :sour let(:event) { approved_event } end - it 'calls MergeRequests::MarkReviewerReviewedService' do + it 'calls MergeRequests::UpdateReviewerStateService' do expect_next_instance_of( - MergeRequests::MarkReviewerReviewedService, + MergeRequests::UpdateReviewerStateService, project: project, current_user: user ) do |service| - expect(service).to receive(:execute).with(merge_request) + expect(service).to receive(:execute).with(merge_request, "reviewed") end consume_event(subscriber: described_class, event: approved_event) end shared_examples 'when object does not exist' do - it 'logs and does not call MergeRequests::MarkReviewerReviewedService' do + it 'logs and does not call MergeRequests::UpdateReviewerStateService' do expect(Sidekiq.logger).to receive(:info).with(hash_including(log_payload)) - expect(MergeRequests::MarkReviewerReviewedService).not_to receive(:new) + expect(MergeRequests::UpdateReviewerStateService).not_to receive(:new) expect { consume_event(subscriber: described_class, event: approved_event) } .not_to raise_exception |