summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/initializers/direct_upload_support_spec.rb7
-rw-r--r--spec/lib/object_storage/direct_upload_spec.rb24
-rw-r--r--spec/support/helpers/stub_object_storage.rb4
3 files changed, 6 insertions, 29 deletions
diff --git a/spec/initializers/direct_upload_support_spec.rb b/spec/initializers/direct_upload_support_spec.rb
index f124e726bac..e51d404e030 100644
--- a/spec/initializers/direct_upload_support_spec.rb
+++ b/spec/initializers/direct_upload_support_spec.rb
@@ -6,7 +6,7 @@ describe 'Direct upload support' do
end
where(:config_name) do
- ['lfs', 'artifacts', 'uploads']
+ %w(lfs artifacts uploads)
end
with_them do
@@ -23,8 +23,9 @@ describe 'Direct upload support' do
end
before do
- allow(Gitlab.config).to receive_messages(to_settings(
- config_name => { object_store: object_store }))
+ allow(Gitlab.config).to receive_messages(to_settings(config_name => {
+ object_store: object_store
+ }))
end
context 'when object storage is enabled' do
diff --git a/spec/lib/object_storage/direct_upload_spec.rb b/spec/lib/object_storage/direct_upload_spec.rb
index 0f86d10b881..5187821e8f4 100644
--- a/spec/lib/object_storage/direct_upload_spec.rb
+++ b/spec/lib/object_storage/direct_upload_spec.rb
@@ -161,28 +161,4 @@ describe ObjectStorage::DirectUpload do
end
end
end
-
- describe '#get_url' do
- # this method can only be tested with integration tests
- end
-
- describe '#delete_url' do
- # this method can only be tested with integration tests
- end
-
- describe '#store_url' do
- # this method can only be tested with integration tests
- end
-
- describe '#multipart_part_upload_url' do
- # this method can only be tested with integration tests
- end
-
- describe '#multipart_complete_url' do
- # this method can only be tested with integration tests
- end
-
- describe '#multipart_abort_url' do
- # this method can only be tested with integration tests
- end
end
diff --git a/spec/support/helpers/stub_object_storage.rb b/spec/support/helpers/stub_object_storage.rb
index 80204bdab8b..bceaf8277ee 100644
--- a/spec/support/helpers/stub_object_storage.rb
+++ b/spec/support/helpers/stub_object_storage.rb
@@ -47,8 +47,8 @@ module StubObjectStorage
end
def stub_object_storage_multipart_init(endpoint, upload_id = "upload_id")
- stub_request(:post, %r{\A#{endpoint}tmp/uploads/[a-z0-9-]*\?uploads\z}).
- to_return status: 200, body: <<-EOS.strip_heredoc
+ stub_request(:post, %r{\A#{endpoint}tmp/uploads/[a-z0-9-]*\?uploads\z})
+ .to_return status: 200, body: <<-EOS.strip_heredoc
<?xml version="1.0" encoding="UTF-8"?>
<InitiateMultipartUploadResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<Bucket>example-bucket</Bucket>