4
5
6
7
8
9
10
11
|
# File 'lib/slimmer/test_helpers/shared_templates.rb', line 4
def stub_shared_component_locales
stub_request(:get, /https:\/\/\S+.gov.uk\/templates\/locales\/.+/).
with(headers: { 'Accept' => '*/*; q=0.5, application/xml', 'Accept-Encoding' => 'gzip, deflate', 'User-Agent' => 'Ruby' }).
to_return(status: 400, headers: {})
stub_request(:get, /https:\/\/\S+.gov.uk\/templates\/locales\/en/).
with(headers: { 'Accept' => '*/*; q=0.5, application/xml', 'Accept-Encoding' => ' gzip, deflate', 'User-Agent' => 'Ruby' }).
to_return(status: 200, body: '{}', headers: {})
end
|