diff options
author | Kamil Trzciński <ayufan@ayufan.eu> | 2017-10-07 11:07:33 +0300 |
---|---|---|
committer | Kamil Trzciński <ayufan@ayufan.eu> | 2017-10-07 11:07:33 +0300 |
commit | 5ee20b637553dcb70590edfa30b81d972de37170 (patch) | |
tree | 7079e097120fc25438b411c6162a1ae81656c129 /spec/models/project_spec.rb | |
parent | c0cfc9ebd26583c444f2cce1a23f939bfa7d8969 (diff) | |
parent | d4f3963e98397a0aee4b7a65c76ae404300b41d1 (diff) |
Merge branch 'master' into '37970-ci-sections-tracking'
# Conflicts:
# db/schema.rb
Diffstat (limited to 'spec/models/project_spec.rb')
-rw-r--r-- | spec/models/project_spec.rb | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/spec/models/project_spec.rb b/spec/models/project_spec.rb index 1c04cb8cb5f..760ea7da322 100644 --- a/spec/models/project_spec.rb +++ b/spec/models/project_spec.rb @@ -77,6 +77,7 @@ describe Project do it { is_expected.to have_many(:uploads).dependent(:destroy) } it { is_expected.to have_many(:pipeline_schedules) } it { is_expected.to have_many(:members_and_requesters) } + it { is_expected.to have_one(:cluster) } context 'after initialized' do it "has a project_feature" do @@ -422,20 +423,10 @@ describe Project do end describe '#repository_storage_path' do - let(:project) { create(:project, repository_storage: 'custom') } - - before do - FileUtils.mkdir('tmp/tests/custom_repositories') - storages = { 'custom' => { 'path' => 'tmp/tests/custom_repositories' } } - allow(Gitlab.config.repositories).to receive(:storages).and_return(storages) - end - - after do - FileUtils.rm_rf('tmp/tests/custom_repositories') - end + let(:project) { create(:project) } it 'returns the repository storage path' do - expect(project.repository_storage_path).to eq('tmp/tests/custom_repositories') + expect(Dir.exist?(project.repository_storage_path)).to be(true) end end |