diff options
Diffstat (limited to 'spec/uploaders')
-rw-r--r-- | spec/uploaders/object_storage_spec.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/uploaders/object_storage_spec.rb b/spec/uploaders/object_storage_spec.rb index a1d8695a8c9..13f70e3f85b 100644 --- a/spec/uploaders/object_storage_spec.rb +++ b/spec/uploaders/object_storage_spec.rb @@ -222,7 +222,11 @@ RSpec.describe ObjectStorage do before do stub_artifacts_object_storage - stub_request(:get, %r{s3.amazonaws.com/#{uploader.path}}).to_return(status: 200, body: '') + + # We need to check the Host header not including the port because AWS does not accept + stub_request(:get, %r{s3.amazonaws.com/#{uploader.path}}) + .with { |request| !request.headers['Host'].to_s.include?(':443') } + .to_return(status: 200, body: '') end it "returns the file" do |