Skip to content

Commit 920826c

Browse files
committed
Fix cops
1 parent 281c181 commit 920826c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

lib/fastlane/plugin/wpmreleasetoolkit/actions/common/upload_to_s3.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,7 @@ def self.available_options
8383
type: String,
8484
verify_block: proc { |key|
8585
next if key.is_a?(String) && !key.empty?
86+
8687
UI.user_error!('The provided key must not be empty. Use nil instead if you want to default to the file basename')
8788
}
8889
),

spec/upload_to_s3_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@
99
end
1010

1111
# Stub head_object to return a specific content_length
12-
def stub_s3_response_for_file(key, exists = true)
12+
def stub_s3_response_for_file(key, exists: true)
1313
content_length = exists == true ? 1 : 0
1414
allow(client).to(receive(:head_object))
15-
.with(bucket: test_bucket, key: key)
16-
.and_return(Aws::S3::Types::HeadObjectOutput.new(content_length: content_length))
15+
.with(bucket: test_bucket, key: key)
16+
.and_return(Aws::S3::Types::HeadObjectOutput.new(content_length: content_length))
1717
end
1818

1919
describe 'uploading a file with valid parameters' do

0 commit comments

Comments
 (0)