summaryrefslogtreecommitdiff
path: root/spec/config
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-10-20 09:40:42 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2022-10-20 09:40:42 +0000
commitee664acb356f8123f4f6b00b73c1e1cf0866c7fb (patch)
treef8479f94a28f66654c6a4f6fb99bad6b4e86a40e /spec/config
parent62f7d5c5b69180e82ae8196b7b429eeffc8e7b4f (diff)
downloadgitlab-ce-ee664acb356f8123f4f6b00b73c1e1cf0866c7fb.tar.gz
Add latest changes from gitlab-org/gitlab@15-5-stable-eev15.5.0-rc42
Diffstat (limited to 'spec/config')
-rw-r--r--spec/config/object_store_settings_spec.rb21
1 files changed, 21 insertions, 0 deletions
diff --git a/spec/config/object_store_settings_spec.rb b/spec/config/object_store_settings_spec.rb
index 8ddb5652dae..9275c809550 100644
--- a/spec/config/object_store_settings_spec.rb
+++ b/spec/config/object_store_settings_spec.rb
@@ -113,6 +113,27 @@ RSpec.describe ObjectStoreSettings do
expect(settings.lfs['object_store']['bucket_prefix']).to eq('lfs')
end
+ context 'with Google CDN enabled' do
+ let(:cdn_config) do
+ {
+ 'provider' => 'Google',
+ 'url' => 'https://cdn.example.org',
+ 'key_name' => 'stanhu-key',
+ 'key' => Base64.urlsafe_encode64(SecureRandom.hex)
+ }
+ end
+
+ before do
+ config['object_store']['objects']['artifacts']['cdn'] = cdn_config
+ end
+
+ it 'populates artifacts CDN config' do
+ subject
+
+ expect(settings.artifacts['object_store']['cdn']).to eq(cdn_config)
+ end
+ end
+
it 'raises an error when a bucket is missing' do
config['object_store']['objects']['lfs'].delete('bucket')