diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-11-23 15:10:59 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-11-23 15:10:59 +0300 |
commit | e1a5a2f484427b549a200c2443da0c1987f6743a (patch) | |
tree | 208e9d37e2bf84e52655853c60ea1db60f6e11eb /spec/initializers | |
parent | 02cf17adf0ff486eb6c91af4e9e7427da2f278e2 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/initializers')
-rw-r--r-- | spec/initializers/6_validations_spec.rb | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/spec/initializers/6_validations_spec.rb b/spec/initializers/6_validations_spec.rb index 4d317a7583e..6422dccc6d5 100644 --- a/spec/initializers/6_validations_spec.rb +++ b/spec/initializers/6_validations_spec.rb @@ -7,10 +7,10 @@ RSpec.describe '6_validations' do describe 'validate_storages_config' do context 'with correct settings' do before do - mock_storages( - 'storage' => Gitlab::GitalyClient::StorageSettings.new('path' => 'tmp/tests/paths/a/b/c'), - 'storage.with_VALID-chars01' => Gitlab::GitalyClient::StorageSettings.new('path' => 'tmp/tests/paths/a/b/d'), - 'gitaly.c.gitlab-prd-164c.internal' => Gitlab::GitalyClient::StorageSettings.new('path' => 'tmp/tests/paths/a/b/e') + stub_storage_settings( + 'storage' => {}, + 'storage.with_VALID-chars01' => {}, + 'gitaly.c.gitlab-prd-164c.internal' => {} ) end @@ -21,7 +21,7 @@ RSpec.describe '6_validations' do context 'with invalid storage names' do before do - mock_storages('name with spaces' => Gitlab::GitalyClient::StorageSettings.new('path' => 'tmp/tests/paths/a/b/c')) + stub_storage_settings('name with spaces' => {}) end it 'throws an error' do @@ -29,8 +29,4 @@ RSpec.describe '6_validations' do end end end - - def mock_storages(storages) - allow(Gitlab.config.repositories).to receive(:storages).and_return(storages) - end end |