From 5263338299a7ef96b919d4aaac04eca3594f6b7e Mon Sep 17 00:00:00 2001 From: Matt Muller Date: Tue, 18 Jun 2024 18:09:07 -0400 Subject: [PATCH] Fix more failing tests --- .../aws-sdk-glacier/lib/aws-sdk-glacier/plugins/account_id.rb | 4 +++- gems/aws-sdk-s3/spec/client_spec.rb | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/gems/aws-sdk-glacier/lib/aws-sdk-glacier/plugins/account_id.rb b/gems/aws-sdk-glacier/lib/aws-sdk-glacier/plugins/account_id.rb index 00f1e3aac8c..d9654a86a8f 100644 --- a/gems/aws-sdk-glacier/lib/aws-sdk-glacier/plugins/account_id.rb +++ b/gems/aws-sdk-glacier/lib/aws-sdk-glacier/plugins/account_id.rb @@ -16,8 +16,10 @@ class AccountId < Seahorse::Client::Plugin class Handler < Seahorse::Client::Handler def call(context) - context.params[:account_id] = nil if context.params[:account_id].empty? context.params[:account_id] ||= context.config.account_id + if context.params[:account_id].empty? + context.params[:account_id] = '-' + end @handler.call(context) end end diff --git a/gems/aws-sdk-s3/spec/client_spec.rb b/gems/aws-sdk-s3/spec/client_spec.rb index ca3534d8e21..bbd262193d0 100644 --- a/gems/aws-sdk-s3/spec/client_spec.rb +++ b/gems/aws-sdk-s3/spec/client_spec.rb @@ -492,7 +492,7 @@ module S3 it 'uses path style addressing for DNS incompatible bucket names' do client = Client.new(stub_responses: true) resp = client.head_bucket(bucket: 'Bucket123') - expect(resp.context.http_request.endpoint.path).to eq('/Bucket123/') + expect(resp.context.http_request.endpoint.path).to eq('/Bucket123') end end