debian-mirror-gitlab/spec/workers/deployments/drop_older_deployments_worker_spec.rb
2021-01-03 14:25:43 +05:30

19 lines
468 B
Ruby

# frozen_string_literal: true
require 'spec_helper'
RSpec.describe Deployments::DropOlderDeploymentsWorker do
subject { described_class.new.perform(deployment&.id) }
describe '#perform' do
let(:deployment) { create(:deployment, :success) }
it 'executes Deployments::OlderDeploymentsDropService' do
expect(Deployments::OlderDeploymentsDropService)
.to receive(:new).with(deployment.id).and_call_original
subject
end
end
end