Project

General

Profile

Actions

Misc #10721

closed

Failing test because of DNS server

Added by anthonycrumley (Anthony Crumley) about 9 years ago. Updated about 9 years ago.


Description

The following test is failing:

[ 5/52] TestNetHTTP#test_failure_message_includes_failed_domain_and_port = 0.32 s

  1. Failure:
    TestNetHTTP#test_failure_message_includes_failed_domain_and_port [/vagrant/test/net/http/test_http.rb:196]:
    Expected "should have raised" to include "doesnotexist.bogus:80".

The problem is caused by my ISP, Charter Cable, returning a search results page instead of a failed DNS lookup for http://doesnotexist.bogus. If I change my DNS server setting on my computer to use Google DNS then the test passes.

The attached patch uses a MiniTest stub to produce the DNS failure which results in the expected error message regardless of how the machine's DNS server responds to http://doesnotexist.bogus.

Thanks for everything you all do,

Anthony


Files

dns_lookup.patch (1.06 KB) dns_lookup.patch anthonycrumley (Anthony Crumley), 01/09/2015 06:29 AM
dns_lookup_v2.patch (1.18 KB) dns_lookup_v2.patch anthonycrumley (Anthony Crumley), 01/10/2015 12:32 AM
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0