gitlab-org--gitlab-foss/spec/workers/expire_build_artifacts_work...

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
499 B
Ruby
Raw Normal View History

# frozen_string_literal: true
2016-06-10 15:27:49 +00:00
require 'spec_helper'
RSpec.describe ExpireBuildArtifactsWorker do
2016-06-10 19:45:06 +00:00
let(:worker) { described_class.new }
2016-06-10 15:27:49 +00:00
describe '#perform' do
it 'executes a service' do
expect_next_instance_of(Ci::JobArtifacts::DestroyAllExpiredService) do |instance|
expect(instance).to receive(:execute).and_call_original
end
expect(worker).to receive(:log_extra_metadata_on_done).with(:destroyed_job_artifacts_count, 0)
worker.perform
end
end
2016-06-10 15:27:49 +00:00
end