debian-mirror-gitlab/spec/workers/partition_creation_worker_spec.rb

20 lines
445 B
Ruby
Raw Normal View History

2020-07-28 23:09:34 +05:30
# frozen_string_literal: true
require "spec_helper"
RSpec.describe PartitionCreationWorker do
describe '#perform' do
let(:creator) { double(create_partitions: nil) }
before do
allow(Gitlab::Database::Partitioning::PartitionCreator).to receive(:new).and_return(creator)
end
it 'delegates to PartitionCreator' do
expect(creator).to receive(:create_partitions)
described_class.new.perform
end
end
end