summaryrefslogtreecommitdiff
path: root/spec/lib/gitlab/gitaly_client/cleanup_service_spec.rb
blob: c42332dc27b35a24241fe7b1b3052db24a4d97af (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
require 'spec_helper'

describe Gitlab::GitalyClient::CleanupService do
  let(:project) { create(:project) }
  let(:storage_name) { project.repository_storage }
  let(:relative_path) { project.disk_path + '.git' }
  let(:client) { described_class.new(project.repository) }

  describe '#apply_bfg_object_map_stream' do
    it 'sends an apply_bfg_object_map_stream message' do
      expect_any_instance_of(Gitaly::CleanupService::Stub)
        .to receive(:apply_bfg_object_map_stream)
        .with(kind_of(Enumerator), kind_of(Hash))
        .and_return([])

      client.apply_bfg_object_map_stream(StringIO.new)
    end
  end
end