Commit 7e634c8f authored by Catalin Irimie's avatar Catalin Irimie

Fix Faraday update spec failures

In the Elasticsearch spec we're hardcoding the UserAgent which
means the UA + Signature need to change with a Faraday update
parent 157888ff
...@@ -49,10 +49,10 @@ RSpec.describe Gitlab::Elastic::Client do ...@@ -49,10 +49,10 @@ RSpec.describe Gitlab::Elastic::Client do
stub_request(:get, 'http://example-elastic:9200/foo/_all/1') stub_request(:get, 'http://example-elastic:9200/foo/_all/1')
.with( .with(
headers: { headers: {
'Authorization' => 'AWS4-HMAC-SHA256 Credential=0/20170303/us-east-1/es/aws4_request, SignedHeaders=content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-opaque-id, Signature=61a04383d24ca21f7ec80cd56c252bc3ecd3a306dbe6681e615416b4b9ec5ecb', 'Authorization' => 'AWS4-HMAC-SHA256 Credential=0/20170303/us-east-1/es/aws4_request, SignedHeaders=content-type;host;user-agent;x-amz-content-sha256;x-amz-date;x-opaque-id, Signature=33a12f5ce6863009a29c856204935d454c32202fc9f321131e31fdd3ae5748c6',
'Content-Type' => 'application/json', 'Content-Type' => 'application/json',
# User-Agent is a part of SignedHeaders; if this changes, the signature will change # User-Agent is a part of SignedHeaders; if this changes, the signature will change
'User-Agent' => 'Faraday v1.0.1', 'User-Agent' => 'Faraday v1.4.2',
'X-Amz-Content-Sha256' => 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855', 'X-Amz-Content-Sha256' => 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855',
'X-Amz-Date' => '20170303T133952Z' 'X-Amz-Date' => '20170303T133952Z'
}) })
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment