diff options
author | Thong Kuah <tkuah@gitlab.com> | 2019-07-24 15:48:44 +1200 |
---|---|---|
committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2019-07-29 19:20:30 -0300 |
commit | 9c8f6e0cdfcf3be90bd819751cf76ba760556d13 (patch) | |
tree | ea57a0c1a211bd37a8ffaadac8dbea4f9a1f455f /spec/lib/gitlab/http_connection_adapter_spec.rb | |
parent | d6a7408fd319749b9cd47690f03720d1a5c088ca (diff) | |
download | gitlab-ce-9c8f6e0cdfcf3be90bd819751cf76ba760556d13.tar.gz |
Stub DNS to return IPv4 addressdeterminstic_dns_specs
Otherwise certain machines return IPv6 first, which is non-deterministic
Diffstat (limited to 'spec/lib/gitlab/http_connection_adapter_spec.rb')
-rw-r--r-- | spec/lib/gitlab/http_connection_adapter_spec.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/lib/gitlab/http_connection_adapter_spec.rb b/spec/lib/gitlab/http_connection_adapter_spec.rb index 930d1f62272..1532fd1103e 100644 --- a/spec/lib/gitlab/http_connection_adapter_spec.rb +++ b/spec/lib/gitlab/http_connection_adapter_spec.rb @@ -3,7 +3,13 @@ require 'spec_helper' describe Gitlab::HTTPConnectionAdapter do + include StubRequests + describe '#connection' do + before do + stub_all_dns('https://example.org', ip_address: '93.184.216.34') + end + context 'when local requests are not allowed' do it 'sets up the connection' do uri = URI('https://example.org') |